-
Notifications
You must be signed in to change notification settings - Fork 676
/
twitter.account.index.tpl
161 lines (142 loc) · 5.95 KB
/
twitter.account.index.tpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<div class="plugin-info">
<span class="pull-right">{insert name="help_link" id='twitter'}</span>
<h2>
<i class="icon-twitter icon-muted"></i> Twitter
</h2>
</div>
{include file="_usermessage.tpl"}
{if count($owner_instances) > 0 }{include file="_usermessage.tpl" field="user_add"}{/if}
{if count($owner_instances) > 0 }
<table class="table">
<tr>
<th><h4 class="pull-left">Account</h4></th>
<th><i class="icon-lock icon-2x icon-muted"></i></th>
{if $user_is_admin}<th><i class="icon-refresh icon-2x icon-muted"></i></th>{/if}
<th><i class="icon-tag icon-2x icon-muted"></i></th>
<th><i class="icon-trash icon-2x icon-muted"></i></th>
</tr>
{foreach from=$owner_instances key=iid item=i name=foo}
<tr>
<td>
<h3 class="lead"><i class="icon-twitter icon-muted"></i> <a href="https://twitter.com/intent/user?screen_name={$i->network_username}">@{$i->network_username}</a></h3>
</td>
<td class="action-button">
<span id="div{$i->id}"><input type="submit" name="submit" class="btn
{if $i->is_public}btnPriv{else}btnPub{/if}" id="{$i->id}" value="{if $i->is_public} Set private{else}Set public{/if}" /></span>
</td>
{if $user_is_admin}
<td class="action-button">
<span id="divactivate{$i->id}"><input type="submit" name="submit" class="btn {if $i->is_active}btnPause{else}btnPlay{/if}" id="{$i->id}" value="{if $i->is_active}Pause crawling{else}Start crawling{/if}" /></span>
</td>
{/if}
<td class="action-button">
<a href="{$site_root_path}account/?p=twitter&u={$i->network_username}&n=twitter#manage_plugin" class="btn btn-info btnHashtag">Saved searches</a>
</td>
<td class="action-button">
<span id="delete{$i->id}"><form method="post" action="{$site_root_path}account/?p=twitter#manage_plugin">
<input type="hidden" name="instance_id" value="{$i->id}">
{insert name="csrf_token"}<input
onClick="return confirm('Do you really want to delete this Twitter account?');"
type="submit" name="action" class="btn btn-danger"
value="Delete" /></form></span>
</td>
</tr>
{/foreach}
</table>
{/if}
{include file="_usermessage.tpl" field="membership_cap"}
{if $oauthorize_link}
<a href="{$oauthorize_link}" class="btn btn-success add-account"><i class="icon-plus icon-white"></i> Add a Twitter account</a>
{/if}
<div id="contact-admin-div" style="display: none;">
{include file="_plugin.admin-request.tpl"}
</div>
{if $user_is_admin}
{include file="_plugin.showhider.tpl"}
{include file="_usermessage.tpl" field="setup"}
<p style="padding:5px">To set up the Twitter plugin:</p>
<ol style="margin-left:40px"><li><a href="https://dev.twitter.com/apps/new" target="_blank" style="text-decoration: underline;">Create a new application on Twitter for ThinkUp</a>.</li>
<li>
Fill in the following settings.<br />
Name: <span style="font-family:Courier;">{$twitter_app_name}</span><br />
Description: <span style="font-family:Courier;">My ThinkUp installation</span><br />
Website:
<small>
<code style="font-family:Courier;" id="clippy_2987">{$thinkup_site_url}</code>
</small>
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
width="100"
height="14"
class="clippy"
id="clippy" >
<param name="movie" value="{$site_root_path}assets/flash/clippy.swf"/>
<param name="allowScriptAccess" value="always" />
<param name="quality" value="high" />
<param name="scale" value="noscale" />
<param NAME="FlashVars" value="id=clippy_2987&copied=copied!&copyto=copy to clipboard">
<param name="bgcolor" value="#FFFFFF">
<param name="wmode" value="opaque">
<embed src="{$site_root_path}assets/flash/clippy.swf"
width="100"
height="14"
name="clippy"
quality="high"
allowScriptAccess="always"
type="application/x-shockwave-flash"
pluginspage="http://www.macromedia.com/go/getflashplayer"
FlashVars="id=clippy_2987&copied=copied!&copyto=copy to clipboard"
bgcolor="#FFFFFF"
wmode="opaque"
/>
</object>
<br />
Callback URL:
<small>
<code style="font-family:Courier;" id="clippy_2988">{$thinkup_site_url}account/?p=twitter</code>
</small>
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
width="100"
height="14"
class="clippy"
id="clippy" >
<param name="movie" value="{$site_root_path}assets/flash/clippy.swf"/>
<param name="allowScriptAccess" value="always" />
<param name="quality" value="high" />
<param name="scale" value="noscale" />
<param NAME="FlashVars" value="id=clippy_2988&copied=copied!&copyto=copy to clipboard">
<param name="bgcolor" value="#FFFFFF">
<param name="wmode" value="opaque">
<embed src="{$site_root_path}assets/flash/clippy.swf"
width="100"
height="14"
name="clippy"
quality="high"
allowScriptAccess="always"
type="application/x-shockwave-flash"
pluginspage="http://www.macromedia.com/go/getflashplayer"
FlashVars="id=clippy_2988&copied=copied!&copyto=copy to clipboard"
bgcolor="#FFFFFF"
wmode="opaque"
/>
</object>
</li>
<li>Set the application Default Access type to "Read-only".</li>
<li>Enter the Twitter-provided consumer key and secret here.</li></ol>
{/if}
{if $options_markup}
<p>
{$options_markup}
</p>
{/if}
{if $user_is_admin}</div>{/if}
{literal}
<script type="text/javascript">
if( required_values_set ) {
$('#add-account-div').show();
} else {
if(! is_admin) {
$('#contact-admin-div').show();
}
}
{/literal}
</script>