WordPress.org

Plugin Directory

Changeset 402859


Ignore:
Timestamp:
06/30/11 15:47:52 (7 years ago)
Author:
SriniG
Message:

Updating to version 1.5, tagging v1.4.4

Location:
quotes-collection
Files:
5 added
11 edited
1 copied

Legend:

Unmodified
Added
Removed
  • quotes-collection/trunk/languages/quotes-collection-ta_IN.po

    r254675 r402859  
    11msgid "" 
    22msgstr "" 
    3 "Project-Id-Version: Quotes Collection 1.1\n" 
     3"Project-Id-Version: Quotes Collection 1.5\n" 
    44"Report-Msgid-Bugs-To: http://wordpress.org/tag/quotes-collection\n" 
    5 "POT-Creation-Date: 2010-06-15 12:26+0530\n" 
    6 "PO-Revision-Date: 2010-06-19 12:10+0530\n" 
    7 "Last-Translator: Srinivasan G <srinig.com@gmail.com>\n" 
     5"POT-Creation-Date: 2011-06-30 13:32+0530\n" 
     6"PO-Revision-Date: 2011-06-30 13:54+0530\n" 
     7"Last-Translator: Srini G <srinig112@gmail.com>\n" 
    88"Language-Team: \n" 
     9"Language: \n" 
    910"MIME-Version: 1.0\n" 
    1011"Content-Type: text/plain; charset=UTF-8\n" 
     
    1516"X-Poedit-SourceCharset: utf-8\n" 
    1617 
    17 #: quotes-collection.php:16 
     18#: quotes-collection-ajax.php:6 
     19#: quotes-collection.php:215 
    1820msgid "Next quote" 
    1921msgstr "அடுத்த வாசகம்" 
    2022 
    21 #: quotes-collection.php:88 
     23#: quotes-collection-ajax.php:7 
    2224msgid "Loading..." 
    2325msgstr "இதோ வருகிறது..." 
    2426 
    25 #: quotes-collection.php:89 
     27#: quotes-collection-ajax.php:8 
    2628msgid "Error getting quote" 
    2729msgstr "வாசகத்தினை மீட்பதில் சிக்கல்" 
    2830 
    29 #: quotes-collection.php:239 
    30 #: quotes-collection.php:264 
     31#: quotes-collection.php:163 
     32msgid "Go to the first page" 
     33msgstr "முதல் பக்கத்திற்கு செல்லவும்" 
     34 
     35#: quotes-collection.php:165 
     36msgid "Go to the previous page" 
     37msgstr "பின் பக்கத்துக்கு செல்லவும்" 
     38 
     39#: quotes-collection.php:169 
     40msgid "Go to the next page" 
     41msgstr "அடுத்த பக்கத்துக்கு செல்லவும்" 
     42 
     43#: quotes-collection.php:171 
     44msgid "Go to the last page" 
     45msgstr "கடைசி ப்க்கத்துக்கு செல்லவும்" 
     46 
     47#: quotes-collection.php:175 
     48msgid "Goto page:" 
     49msgstr "பக்கங்கள்:" 
     50 
     51#: quotes-collection-admin.php:14 
     52msgid "Nothing added to the database." 
     53msgstr "சேர்ப்பதற்கு ஒன்றுமில்லை." 
     54 
     55#: quotes-collection-admin.php:18 
     56#: quotes-collection-admin.php:55 
     57msgid "Database table not found" 
     58msgstr "Database table காணவில்லை!" 
     59 
     60#: quotes-collection-admin.php:42 
     61#: quotes-collection-admin.php:84 
     62#: quotes-collection-admin.php:98 
     63msgid "There was an error in the MySQL query" 
     64msgstr "MySQL queryஇல் பிழை இருந்தது" 
     65 
     66#: quotes-collection-admin.php:44 
     67msgid "Quote added" 
     68msgstr "வாசகம் சேர்க்கப்பட்டது" 
     69 
     70#: quotes-collection-admin.php:50 
     71msgid "Quote not updated." 
     72msgstr "வாசகம் திருத்தப்படவில்லை" 
     73 
     74#: quotes-collection-admin.php:86 
     75msgid "Changes saved" 
     76msgstr "மாற்றங்கள் சேமிக்கப்பட்டன" 
     77 
     78#: quotes-collection-admin.php:100 
     79msgid "Quote deleted" 
     80msgstr "வாசகம் அழிக்கப்பட்டது" 
     81 
     82#: quotes-collection-admin.php:102 
     83msgid "The quote cannot be deleted" 
     84msgstr "வாசகத்தினை அழிக்க முடியவில்லை" 
     85 
     86#: quotes-collection-admin.php:118 
     87#: quotes-collection-admin.php:220 
     88msgid "Add Quote" 
     89msgstr "சேர்க்கவும்" 
     90 
     91#: quotes-collection-admin.php:135 
     92#: quotes-collection-admin.php:224 
     93msgid "Save changes" 
     94msgstr "மாற்றங்களை சேமிக்கவும்" 
     95 
     96#: quotes-collection-admin.php:136 
     97msgid "Back" 
     98msgstr "பின்வாங்கவும்" 
     99 
     100#: quotes-collection-admin.php:140 
     101#: quotes-collection-admin.php:386 
     102msgid "The quote" 
     103msgstr "வாசகம்" 
     104 
     105#: quotes-collection-admin.php:141 
     106#: quotes-collection-admin.php:368 
     107#: quotes-collection-admin.php:388 
     108msgid "Author" 
     109msgstr "சொன்னவர்" 
     110 
     111#: quotes-collection-admin.php:142 
     112#: quotes-collection-admin.php:369 
     113#: quotes-collection-admin.php:388 
     114msgid "Source" 
     115msgstr "எங்கே சொல்லப்பட்டது" 
     116 
     117#: quotes-collection-admin.php:143 
     118#: quotes-collection-admin.php:390 
     119msgid "Tags" 
     120msgstr "குறிச்சொற்கள்" 
     121 
     122#: quotes-collection-admin.php:144 
     123#: quotes-collection-admin.php:391 
     124msgid "Public?" 
     125msgstr "பொதுப் பார்வைக்கா?" 
     126 
     127#: quotes-collection-admin.php:145 
     128msgid "optional" 
     129msgstr "அவசியமில்லை" 
     130 
     131#: quotes-collection-admin.php:146 
     132msgid "comma separated" 
     133msgstr "ஒன்றுக்கு மேற்பட்ட சொற்களை 'கமா'வால் பிரிக்கவும்" 
     134 
     135#: quotes-collection-admin.php:183 
     136#: quotes-collection-admin.php:199 
     137msgid "Nothing done!" 
     138msgstr "ஒன்றும் செய்வதற்கில்லை!" 
     139 
     140#: quotes-collection-admin.php:191 
     141msgid "Selected quotes made public" 
     142msgstr "தேர்ந்தெடுக்கப்பட்ட வாசகங்கள் பொதுப் பார்வைக்கு வைக்கப்பட்டன." 
     143 
     144#: quotes-collection-admin.php:193 
     145msgid "Selected quotes made private" 
     146msgstr "தேர்ந்தெடுக்கப்பட்ட வாசகங்கள் பொதுப் பார்வையிலிருந்து மறைக்கப்பட்டன." 
     147 
     148#: quotes-collection-admin.php:204 
     149msgid "Quote(s) deleted" 
     150msgstr "வாசகங்கள் அழிக்கப்பட்டன" 
     151 
     152#: quotes-collection-admin.php:231 
     153msgid "Edit quote" 
     154msgstr "வாசகத்தினை திருத்தவும்" 
     155 
     156#: quotes-collection-admin.php:258 
     157#: quotes-collection-admin.php:267 
     158#: quotes-collection-admin.php:412 
     159msgid "Add new quote" 
     160msgstr "புதிய வாசகம் ஒன்றை சேர்க்கவும்" 
     161 
     162#: quotes-collection-admin.php:263 
     163#: quotes-collection-admin.php:406 
     164msgid "No quotes in the database" 
     165msgstr "வாசகங்கள் ஏதும் இதுவரை சேர்க்கப்படவில்லை" 
     166 
     167#: quotes-collection-admin.php:337 
     168msgid "Edit" 
     169msgstr "திருத்தவும்" 
     170 
     171#: quotes-collection-admin.php:337 
     172msgid "Are you sure you want to delete this quote?" 
     173msgstr "இந்த வாசகத்தினை அழித்துத்தான் ஆக வேண்டுமா?" 
     174 
     175#: quotes-collection-admin.php:337 
     176#: quotes-collection-admin.php:358 
     177msgid "Delete" 
     178msgstr "அழிக்கவும்" 
     179 
     180#: quotes-collection-admin.php:344 
     181msgid "No" 
     182msgstr "இல்லை" 
     183 
     184#: quotes-collection-admin.php:345 
     185#, fuzzy 
     186msgid "Yes" 
     187msgstr "ஆம்" 
     188 
     189#: quotes-collection-admin.php:357 
     190msgid "Bulk Actions" 
     191msgstr "மொத்தமாக..." 
     192 
     193#: quotes-collection-admin.php:359 
     194msgid "Make public" 
     195msgstr "பொதுப் பார்வைக்கு வைக்கவும்" 
     196 
     197#: quotes-collection-admin.php:360 
     198msgid "Keep private" 
     199msgstr "பொதுப் பார்வையிலிருந்து மறைக்கவும்." 
     200 
     201#: quotes-collection-admin.php:362 
     202msgid "Apply" 
     203msgstr "செய்க" 
     204 
     205#: quotes-collection-admin.php:364 
     206msgid "Sort by: " 
     207msgstr "வாசகங்களின் வரிசை முறை: " 
     208 
     209#: quotes-collection-admin.php:366 
     210#: quotes-collection-admin.php:367 
     211msgid "Quote" 
     212msgstr "வாசகம்" 
     213 
     214#: quotes-collection-admin.php:370 
     215msgid "Date added" 
     216msgstr "சேர்த்த நாள்" 
     217 
     218#: quotes-collection-admin.php:371 
     219msgid "Date updated" 
     220msgstr "திருத்திய நாள்" 
     221 
     222#: quotes-collection-admin.php:372 
     223msgid "Visibility" 
     224msgstr "பொதுப் பார்வை" 
     225 
     226#: quotes-collection-admin.php:375 
     227msgid "Go" 
     228msgstr "ஆகட்டும்" 
     229 
     230#: quotes-collection-admin.php:377 
     231#: quotes-collection-admin.php:397 
     232#, php-format 
     233msgid "%d quote" 
     234msgid_plural "%d quotes" 
     235msgstr[0] "%d வாசகம்" 
     236msgstr[1] "%d வாசகங்கள்" 
     237 
     238#: quotes-collection-widget.php:13 
     239#: quotes-collection-widget.php:38 
    31240msgid "Random Quote" 
    32241msgstr "வாசகம் ஒன்று" 
    33242 
    34 #: quotes-collection.php:291 
     243#: quotes-collection-widget.php:65 
    35244msgid "none" 
    36245msgstr "-" 
    37246 
    38 #: quotes-collection.php:307 
     247#: quotes-collection-widget.php:84 
    39248msgid "Title" 
    40249msgstr "தலைப்பு" 
    41250 
    42 #: quotes-collection.php:308 
     251#: quotes-collection-widget.php:85 
    43252msgid "Show author?" 
    44253msgstr "சொன்னவரின் பெயரை காண்பிக்க வேண்டுமா?" 
    45254 
    46 #: quotes-collection.php:309 
     255#: quotes-collection-widget.php:86 
    47256msgid "Show source?" 
    48257msgstr "எங்கே சொல்லப்பட்டது என்பதை காண்பிக்க வேண்டுமா?" 
    49258 
    50 #: quotes-collection.php:310 
     259#: quotes-collection-widget.php:87 
    51260msgid "Ajax refresh feature" 
    52261msgstr "அடுத்த வாசகத்தினை மீட்கும் சுட்டி" 
    53262 
    54 #: quotes-collection.php:311 
     263#: quotes-collection-widget.php:88 
    55264msgid "Advanced options" 
    56265msgstr "மற்றைய குறிப்புகள்" 
    57266 
    58 #: quotes-collection.php:313 
     267#: quotes-collection-widget.php:90 
    59268msgid "Random refresh" 
    60269msgstr "எடுத்தேற்ற மீட்டல் முறை" 
    61270 
    62 #: quotes-collection.php:313 
     271#: quotes-collection-widget.php:90 
    63272msgid "Unchecking this will rotate quotes in the order added, latest first." 
    64273msgstr "இல்லை என்றால் வாசகங்கள் கடைசியாக சேர்க்கப்பட்ட வரிசையில் ஒன்றன் பின் ஒன்றாக மீட்கப்படும். " 
    65274 
    66 #: quotes-collection.php:314 
     275#: quotes-collection-widget.php:91 
    67276msgid "Auto refresh" 
    68277msgstr "தானியக்க மீட்டல் முறை" 
    69278 
    70 #: quotes-collection.php:314 
     279#: quotes-collection-widget.php:91 
    71280msgid "every" 
    72281msgstr "ஒவ்வொரு" 
    73282 
    74 #: quotes-collection.php:314 
     283#: quotes-collection-widget.php:91 
    75284msgid "sec" 
    76285msgstr "வினாடிகளும்" 
    77286 
    78 #: quotes-collection.php:315 
     287#: quotes-collection-widget.php:92 
    79288msgid "Tags filter" 
    80289msgstr "குறிச்சொற்கள்" 
    81290 
    82 #: quotes-collection.php:315 
     291#: quotes-collection-widget.php:92 
    83292msgid "Comma separated" 
    84 msgstr "comma separated" 
    85  
    86 #: quotes-collection.php:316 
     293msgstr "ஒன்றுக்கு மேற்பட்ட சொற்களை 'கமா'வால் பிரிக்கவும்" 
     294 
     295#: quotes-collection-widget.php:93 
    87296msgid "Character limit" 
    88297msgstr "வாசகத்தின் அதிகபட்ச நீளம்" 
    89298 
    90 #: quotes-collection.php:335 
    91 msgid "Nothing added to the database." 
    92 msgstr "சேர்ப்பதற்கு ஒன்றுமில்லை." 
    93  
    94 #: quotes-collection.php:339 
    95 #: quotes-collection.php:376 
    96 msgid "Database table not found" 
    97 msgstr "Database table காணவில்லை!" 
    98  
    99 #: quotes-collection.php:363 
    100 #: quotes-collection.php:405 
    101 #: quotes-collection.php:419 
    102 msgid "There was an error in the MySQL query" 
    103 msgstr "MySQL queryஇல் பிழை இருந்தது" 
    104  
    105 #: quotes-collection.php:365 
    106 msgid "Quote added" 
    107 msgstr "வாசகம் சேர்க்கப்பட்டது" 
    108  
    109 #: quotes-collection.php:371 
    110 msgid "Quote not updated." 
    111 msgstr "வாசகம் திருத்தப்படவில்லை" 
    112  
    113 #: quotes-collection.php:407 
    114 msgid "Changes saved" 
    115 msgstr "மாற்றங்கள் சேமிக்கப்பட்டன" 
    116  
    117 #: quotes-collection.php:421 
    118 msgid "Quote deleted" 
    119 msgstr "வாசகம் அழிக்கப்பட்டது" 
    120  
    121 #: quotes-collection.php:423 
    122 msgid "The quote cannot be deleted" 
    123 msgstr "வாசகத்தினை அழிக்க முடியவில்லை" 
    124  
    125 #: quotes-collection.php:439 
    126 #: quotes-collection.php:536 
    127 msgid "Add Quote" 
    128 msgstr "சேர்க்கவும்" 
    129  
    130 #: quotes-collection.php:455 
    131 #: quotes-collection.php:540 
    132 msgid "Save changes" 
    133 msgstr "மாற்றங்களை சேமிக்கவும்" 
    134  
    135 #: quotes-collection.php:456 
    136 msgid "Back" 
    137 msgstr "பின்வாங்கவும்" 
    138  
    139 #: quotes-collection.php:460 
    140 #: quotes-collection.php:646 
    141 msgid "The quote" 
    142 msgstr "வாசகம்" 
    143  
    144 #: quotes-collection.php:461 
    145 #: quotes-collection.php:629 
    146 #: quotes-collection.php:648 
    147 msgid "Author" 
    148 msgstr "சொன்னவர்" 
    149  
    150 #: quotes-collection.php:462 
    151 #: quotes-collection.php:630 
    152 #: quotes-collection.php:648 
    153 msgid "Source" 
    154 msgstr "எங்கே சொல்லப்பட்டது" 
    155  
    156 #: quotes-collection.php:463 
    157 #: quotes-collection.php:650 
    158 msgid "Tags" 
    159 msgstr "குறிச்சொற்கள்" 
    160  
    161 #: quotes-collection.php:464 
    162 #: quotes-collection.php:651 
    163 msgid "Public?" 
    164 msgstr "பொதுப் பார்வைக்கா?" 
    165  
    166 #: quotes-collection.php:465 
    167 msgid "optional" 
    168 msgstr "அவசியமில்லை" 
    169  
    170 #: quotes-collection.php:466 
    171 msgid "comma separated" 
    172 msgstr "comma separated" 
    173  
    174 #: quotes-collection.php:503 
    175 #: quotes-collection.php:519 
    176 msgid "Nothing done!" 
    177 msgstr "ஒன்றும் செய்வதற்கில்லை!" 
    178  
    179 #: quotes-collection.php:511 
    180 msgid "Selected quotes made public" 
    181 msgstr "தேர்ந்தெடுக்கப்பட்ட வாசகங்கள் பொதுப் பார்வைக்கு வைக்கப்பட்டன." 
    182  
    183 #: quotes-collection.php:513 
    184 msgid "Selected quotes made private" 
    185 msgstr "தேர்ந்தெடுக்கப்பட்ட வாசகங்கள் பொதுப் பார்வையிலிருந்து மறைக்கப்பட்டன." 
    186  
    187 #: quotes-collection.php:524 
    188 msgid "Quote(s) deleted" 
    189 msgstr "வாசகங்கள் அழிக்கப்பட்டன" 
    190  
    191 #: quotes-collection.php:545 
    192 msgid "Edit quote" 
    193 msgstr "வாசகத்தினை திருத்தவும்" 
    194  
    195 #: quotes-collection.php:555 
    196 #: quotes-collection.php:606 
    197 #: quotes-collection.php:621 
    198 #: quotes-collection.php:660 
    199 msgid "Delete" 
    200 msgstr "அழிக்கவும்" 
    201  
    202 #: quotes-collection.php:557 
    203 #: quotes-collection.php:622 
    204 #: quotes-collection.php:661 
    205 msgid "Make public" 
    206 msgstr "பொதுப் பார்வைக்கு வைக்கவும்" 
    207  
    208 #: quotes-collection.php:560 
    209 #: quotes-collection.php:623 
    210 #: quotes-collection.php:662 
    211 msgid "Keep private" 
    212 msgstr "பொதுப் பார்வையிலிருந்து மறைக்கவும்." 
    213  
    214 #: quotes-collection.php:605 
    215 msgid "Edit" 
    216 msgstr "திருத்தவும்" 
    217  
    218 #: quotes-collection.php:606 
    219 msgid "Are you sure you want to delete this quote?" 
    220 msgstr "இந்த வாசகத்தினை அழித்துத்தான் ஆக வேண்டுமா?" 
    221  
    222 #: quotes-collection.php:613 
    223 #, php-format 
    224 msgid "Currently, you have %d quote." 
    225 msgid_plural "Currently, you have %d quotes." 
    226 msgstr[0] "இதுவரை ஒரு வாசகம் சேர்க்கப்பட்டுள்ளது" 
    227 msgstr[1] "இதுவரை %d வாசகங்கள் சேர்க்கப்பட்டுள்ளன" 
    228  
    229 #: quotes-collection.php:615 
    230 #: quotes-collection.php:677 
    231 msgid "Add new quote" 
    232 msgstr "புதிய வாசகம் ஒன்றை சேர்க்கவும்" 
    233  
    234 #: quotes-collection.php:625 
    235 msgid "Sort by: " 
    236 msgstr "வாசகங்களின் வரிசை முறை: " 
    237  
    238 #: quotes-collection.php:627 
    239 #: quotes-collection.php:628 
    240 msgid "Quote" 
    241 msgstr "வாசகம்" 
    242  
    243 #: quotes-collection.php:631 
    244 msgid "Date added" 
    245 msgstr "சேர்த்த நாள்" 
    246  
    247 #: quotes-collection.php:632 
    248 msgid "Date updated" 
    249 msgstr "திருத்திய நாள்" 
    250  
    251 #: quotes-collection.php:633 
    252 msgid "Visibility" 
    253 msgstr "பொதுப் பார்வை" 
    254  
    255 #: quotes-collection.php:636 
    256 msgid "Go" 
    257 msgstr "ஆகட்டும்" 
    258  
    259 #: quotes-collection.php:652 
    260 msgid "Action" 
    261 msgstr "வாசகத்தினை திருத்த/அழிக்க" 
    262  
    263 #: quotes-collection.php:671 
    264 msgid "No quotes in the database" 
    265 msgstr "வாசகங்கள் ஏதும் இதுவரை சேர்க்கப்படவில்லை" 
     299#~ msgid "no" 
     300#~ msgstr "இல்லை" 
     301 
     302#~ msgid "Currently, you have %d quote." 
     303 
     304#~ msgid_plural "Currently, you have %d quotes." 
     305#~ msgstr[0] "இதுவரை ஒரு வாசகம் சேர்க்கப்பட்டுள்ளது" 
     306#~ msgstr[1] "இதுவரை %d வாசகங்கள் சேர்க்கப்பட்டுள்ளன" 
    266307 
    267308#~ msgid "Click here" 
    268309#~ msgstr "இங்கே சென்று" 
     310 
    269311#~ msgid "to manage your collection of quotes" 
    270312#~ msgstr "நீங்கள் சேர்த்து வைத்துள்ள வாசகங்களை தொகுக்கவும்" 
     313 
    271314#~ msgid "Visible?" 
    272315#~ msgstr "Visible?" 
     316 
    273317#~ msgid "Visibility status of selected quotes set to '%s'" 
    274318#~ msgstr "தேர்ந்தெடுக்கப்பட்ட வாசகங்கள் %s ஆக்கப்பட்டன" 
     319 
    275320#~ msgid "Make invisible" 
    276321#~ msgstr "invisible ஆக்கவும்" 
    277  
  • quotes-collection/trunk/languages/quotes-collection.pot

    r253475 r402859  
    11# Quotes Collection plugin for WordPress: Localization template. 
    2 # Copyright (C) 2010 Srini G 
     2# Copyright (C) 2011 Srini G 
    33# This file is distributed under the same license as the Quotes Collection package. 
    4 # Srini G <srinig.com@gmail.com>, 2010. 
     4# Srini G <srinig.com@gmail.com>, 2011. 
    55# 
    66#, fuzzy 
    77msgid "" 
    88msgstr "" 
    9 "Project-Id-Version: Quotes Collection 1.4\n" 
     9"Project-Id-Version: Quotes Collection 1.5\n" 
    1010"Report-Msgid-Bugs-To: http://wordpress.org/tag/quotes-collection\n" 
    11 "POT-Creation-Date: 2010-06-15 12:26+0530\n" 
     11"POT-Creation-Date: 2011-06-30 13:32+0530\n" 
    1212"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 
    1313"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" 
     
    1818"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" 
    1919 
    20 #: quotes-collection.php:16 
     20 
     21 
     22#: quotes-collection-ajax.php:6 
     23#: quotes-collection.php:215 
    2124msgid "Next quote" 
    2225msgstr "" 
    2326 
    24 #: quotes-collection.php:88 
     27#: quotes-collection-ajax.php:7 
    2528msgid "Loading..." 
    2629msgstr "" 
    2730 
    28 #: quotes-collection.php:89 
     31#: quotes-collection-ajax.php:8 
    2932msgid "Error getting quote" 
    3033msgstr "" 
    3134 
    32 #: quotes-collection.php:239 
    33 #: quotes-collection.php:264 
    34 msgid "Random Quote" 
    35 msgstr "" 
    36  
    37 #: quotes-collection.php:291 
    38 msgid "none" 
    39 msgstr "" 
    40  
    41 #: quotes-collection.php:307 
    42 msgid "Title" 
    43 msgstr "" 
    44  
    45 #: quotes-collection.php:308 
    46 msgid "Show author?" 
    47 msgstr "" 
    48  
    49 #: quotes-collection.php:309 
    50 msgid "Show source?" 
    51 msgstr "" 
    52  
    53 #: quotes-collection.php:310 
    54 msgid "Ajax refresh feature" 
    55 msgstr "" 
    56  
    57 #: quotes-collection.php:311 
    58 msgid "Advanced options" 
    59 msgstr "" 
    60  
    61 #: quotes-collection.php:313 
    62 msgid "Random refresh" 
    63 msgstr "" 
    64  
    65 #: quotes-collection.php:313 
    66 msgid "Unchecking this will rotate quotes in the order added, latest first." 
    67 msgstr "" 
    68  
    69 #: quotes-collection.php:314 
    70 msgid "Auto refresh" 
    71 msgstr "" 
    72  
    73 #: quotes-collection.php:314 
    74 msgid "every" 
    75 msgstr "" 
    76  
    77 #: quotes-collection.php:314 
    78 msgid "sec" 
    79 msgstr "" 
    80  
    81 #: quotes-collection.php:315 
    82 msgid "Tags filter" 
    83 msgstr "" 
    84  
    85 #: quotes-collection.php:315 
    86 msgid "Comma separated" 
    87 msgstr "" 
    88  
    89 #: quotes-collection.php:316 
    90 msgid "Character limit" 
    91 msgstr "" 
    92  
    93 #: quotes-collection.php:335 
     35#: quotes-collection.php:163 
     36msgid "Go to the first page" 
     37msgstr "" 
     38 
     39#: quotes-collection.php:165 
     40msgid "Go to the previous page" 
     41msgstr "" 
     42 
     43#: quotes-collection.php:169 
     44msgid "Go to the next page" 
     45msgstr "" 
     46 
     47#: quotes-collection.php:171 
     48msgid "Go to the last page" 
     49msgstr "" 
     50 
     51#: quotes-collection.php:175 
     52msgid "Goto page:" 
     53msgstr "" 
     54 
     55#: quotes-collection-admin.php:14 
    9456msgid "Nothing added to the database." 
    9557msgstr "" 
    9658 
    97 #: quotes-collection.php:339 
    98 #: quotes-collection.php:376 
     59#: quotes-collection-admin.php:18 
     60#: quotes-collection-admin.php:55 
    9961msgid "Database table not found" 
    10062msgstr "" 
    10163 
    102 #: quotes-collection.php:363 
    103 #: quotes-collection.php:405 
    104 #: quotes-collection.php:419 
     64#: quotes-collection-admin.php:42 
     65#: quotes-collection-admin.php:84 
     66#: quotes-collection-admin.php:98 
    10567msgid "There was an error in the MySQL query" 
    10668msgstr "" 
    10769 
    108 #: quotes-collection.php:365 
     70#: quotes-collection-admin.php:44 
    10971msgid "Quote added" 
    11072msgstr "" 
    11173 
    112 #: quotes-collection.php:371 
     74#: quotes-collection-admin.php:50 
    11375msgid "Quote not updated." 
    11476msgstr "" 
    11577 
    116 #: quotes-collection.php:407 
     78#: quotes-collection-admin.php:86 
    11779msgid "Changes saved" 
    11880msgstr "" 
    11981 
    120 #: quotes-collection.php:421 
     82#: quotes-collection-admin.php:100 
    12183msgid "Quote deleted" 
    12284msgstr "" 
    12385 
    124 #: quotes-collection.php:423 
     86#: quotes-collection-admin.php:102 
    12587msgid "The quote cannot be deleted" 
    12688msgstr "" 
    12789 
    128 #: quotes-collection.php:439 
    129 #: quotes-collection.php:536 
     90#: quotes-collection-admin.php:118 
     91#: quotes-collection-admin.php:220 
    13092msgid "Add Quote" 
    13193msgstr "" 
    13294 
    133 #: quotes-collection.php:455 
    134 #: quotes-collection.php:540 
     95#: quotes-collection-admin.php:135 
     96#: quotes-collection-admin.php:224 
    13597msgid "Save changes" 
    13698msgstr "" 
    13799 
    138 #: quotes-collection.php:456 
     100#: quotes-collection-admin.php:136 
    139101msgid "Back" 
    140102msgstr "" 
    141103 
    142 #: quotes-collection.php:460 
    143 #: quotes-collection.php:646 
     104#: quotes-collection-admin.php:140 
     105#: quotes-collection-admin.php:386 
    144106msgid "The quote" 
    145107msgstr "" 
    146108 
    147 #: quotes-collection.php:461 
    148 #: quotes-collection.php:629 
    149 #: quotes-collection.php:648 
     109#: quotes-collection-admin.php:141 
     110#: quotes-collection-admin.php:368 
     111#: quotes-collection-admin.php:388 
    150112msgid "Author" 
    151113msgstr "" 
    152114 
    153 #: quotes-collection.php:462 
    154 #: quotes-collection.php:630 
    155 #: quotes-collection.php:648 
     115#: quotes-collection-admin.php:142 
     116#: quotes-collection-admin.php:369 
     117#: quotes-collection-admin.php:388 
    156118msgid "Source" 
    157119msgstr "" 
    158120 
    159 #: quotes-collection.php:463 
    160 #: quotes-collection.php:650 
     121#: quotes-collection-admin.php:143 
     122#: quotes-collection-admin.php:390 
    161123msgid "Tags" 
    162124msgstr "" 
    163125 
    164 #: quotes-collection.php:464 
    165 #: quotes-collection.php:651 
     126#: quotes-collection-admin.php:144 
     127#: quotes-collection-admin.php:391 
    166128msgid "Public?" 
    167129msgstr "" 
    168130 
    169 #: quotes-collection.php:465 
     131#: quotes-collection-admin.php:145 
    170132msgid "optional" 
    171133msgstr "" 
    172134 
    173 #: quotes-collection.php:466 
     135#: quotes-collection-admin.php:146 
    174136msgid "comma separated" 
    175137msgstr "" 
    176138 
    177 #: quotes-collection.php:503 
    178 #: quotes-collection.php:519 
     139#: quotes-collection-admin.php:183 
     140#: quotes-collection-admin.php:199 
    179141msgid "Nothing done!" 
    180142msgstr "" 
    181143 
    182 #: quotes-collection.php:511 
     144#: quotes-collection-admin.php:191 
    183145msgid "Selected quotes made public" 
    184146msgstr "" 
    185147 
    186 #: quotes-collection.php:513 
     148#: quotes-collection-admin.php:193 
    187149msgid "Selected quotes made private" 
    188150msgstr "" 
    189151 
    190 #: quotes-collection.php:524 
     152#: quotes-collection-admin.php:204 
    191153msgid "Quote(s) deleted" 
    192154msgstr "" 
    193155 
    194 #: quotes-collection.php:545 
     156#: quotes-collection-admin.php:231 
    195157msgid "Edit quote" 
    196158msgstr "" 
    197159 
    198 #: quotes-collection.php:555 
    199 #: quotes-collection.php:606 
    200 #: quotes-collection.php:621 
    201 #: quotes-collection.php:660 
     160#: quotes-collection-admin.php:258 
     161#: quotes-collection-admin.php:267 
     162#: quotes-collection-admin.php:412 
     163msgid "Add new quote" 
     164msgstr "" 
     165 
     166#: quotes-collection-admin.php:263 
     167#: quotes-collection-admin.php:406 
     168msgid "No quotes in the database" 
     169msgstr "" 
     170 
     171#: quotes-collection-admin.php:337 
     172msgid "Edit" 
     173msgstr "" 
     174 
     175#: quotes-collection-admin.php:337 
     176msgid "Are you sure you want to delete this quote?" 
     177msgstr "" 
     178 
     179#: quotes-collection-admin.php:337 
     180#: quotes-collection-admin.php:358 
    202181msgid "Delete" 
    203182msgstr "" 
    204183 
    205 #: quotes-collection.php:557 
    206 #: quotes-collection.php:622 
    207 #: quotes-collection.php:661 
     184#: quotes-collection-admin.php:344 
     185msgid "No" 
     186msgstr "" 
     187 
     188#: quotes-collection-admin.php:345 
     189msgid "Yes" 
     190msgstr "" 
     191 
     192#: quotes-collection-admin.php:357 
     193msgid "Bulk Actions" 
     194msgstr "" 
     195 
     196#: quotes-collection-admin.php:359 
    208197msgid "Make public" 
    209198msgstr "" 
    210199 
    211 #: quotes-collection.php:560 
    212 #: quotes-collection.php:623 
    213 #: quotes-collection.php:662 
     200#: quotes-collection-admin.php:360 
    214201msgid "Keep private" 
    215202msgstr "" 
    216203 
    217 #: quotes-collection.php:605 
    218 msgid "Edit" 
    219 msgstr "" 
    220  
    221 #: quotes-collection.php:606 
    222 msgid "Are you sure you want to delete this quote?" 
    223 msgstr "" 
    224  
    225 #: quotes-collection.php:613 
     204#: quotes-collection-admin.php:362 
     205msgid "Apply" 
     206msgstr "" 
     207 
     208#: quotes-collection-admin.php:364 
     209msgid "Sort by: " 
     210msgstr "" 
     211 
     212#: quotes-collection-admin.php:366 
     213#: quotes-collection-admin.php:367 
     214msgid "Quote" 
     215msgstr "" 
     216 
     217#: quotes-collection-admin.php:370 
     218msgid "Date added" 
     219msgstr "" 
     220 
     221#: quotes-collection-admin.php:371 
     222msgid "Date updated" 
     223msgstr "" 
     224 
     225#: quotes-collection-admin.php:372 
     226msgid "Visibility" 
     227msgstr "" 
     228 
     229#: quotes-collection-admin.php:375 
     230msgid "Go" 
     231msgstr "" 
     232 
     233#: quotes-collection-admin.php:377 
     234#: quotes-collection-admin.php:397 
    226235#, php-format 
    227 msgid "Currently, you have %d quote." 
    228 msgid_plural "Currently, you have %d quotes." 
     236msgid "%d quote" 
     237msgid_plural "%d quotes" 
    229238msgstr[0] "" 
    230239msgstr[1] "" 
    231240 
    232 #: quotes-collection.php:615 
    233 #: quotes-collection.php:677 
    234 msgid "Add new quote" 
    235 msgstr "" 
    236  
    237 #: quotes-collection.php:625 
    238 msgid "Sort by: " 
    239 msgstr "" 
    240  
    241 #: quotes-collection.php:627 
    242 #: quotes-collection.php:628 
    243 msgid "Quote" 
    244 msgstr "" 
    245  
    246 #: quotes-collection.php:631 
    247 msgid "Date added" 
    248 msgstr "" 
    249  
    250 #: quotes-collection.php:632 
    251 msgid "Date updated" 
    252 msgstr "" 
    253  
    254 #: quotes-collection.php:633 
    255 msgid "Visibility" 
    256 msgstr "" 
    257  
    258 #: quotes-collection.php:636 
    259 msgid "Go" 
    260 msgstr "" 
    261  
    262 #: quotes-collection.php:652 
    263 msgid "Action" 
    264 msgstr "" 
    265  
    266 #: quotes-collection.php:671 
    267 msgid "No quotes in the database" 
    268 msgstr "" 
    269  
     241#: quotes-collection-widget.php:13 
     242#: quotes-collection-widget.php:38 
     243msgid "Random Quote" 
     244msgstr "" 
     245 
     246#: quotes-collection-widget.php:65 
     247msgid "none" 
     248msgstr "" 
     249 
     250#: quotes-collection-widget.php:84 
     251msgid "Title" 
     252msgstr "" 
     253 
     254#: quotes-collection-widget.php:85 
     255msgid "Show author?" 
     256msgstr "" 
     257 
     258#: quotes-collection-widget.php:86 
     259msgid "Show source?" 
     260msgstr "" 
     261 
     262#: quotes-collection-widget.php:87 
     263msgid "Ajax refresh feature" 
     264msgstr "" 
     265 
     266#: quotes-collection-widget.php:88 
     267msgid "Advanced options" 
     268msgstr "" 
     269 
     270#: quotes-collection-widget.php:90 
     271msgid "Random refresh" 
     272msgstr "" 
     273 
     274#: quotes-collection-widget.php:90 
     275msgid "Unchecking this will rotate quotes in the order added, latest first." 
     276msgstr "" 
     277 
     278#: quotes-collection-widget.php:91 
     279msgid "Auto refresh" 
     280msgstr "" 
     281 
     282#: quotes-collection-widget.php:91 
     283msgid "every" 
     284msgstr "" 
     285 
     286#: quotes-collection-widget.php:91 
     287msgid "sec" 
     288msgstr "" 
     289 
     290#: quotes-collection-widget.php:92 
     291msgid "Tags filter" 
     292msgstr "" 
     293 
     294#: quotes-collection-widget.php:92 
     295msgid "Comma separated" 
     296msgstr "" 
     297 
     298#: quotes-collection-widget.php:93 
     299msgid "Character limit" 
     300msgstr "" 
     301 
  • quotes-collection/trunk/quotes-collection-ajax.php

    r253475 r402859  
    11<?php 
    2 // If you have your 'wp-content' directory in a place other than the default location, please specify your blog directory here. This is not your blog url. It is the address in your server. For example: '/public_html/myblog' 
    3 $blogdir = "";  
     2function quotescollection_scripts() 
     3{ 
     4    global $quotescollection_auto_refresh_max, $quotescollection_next_quote; 
    45 
    5 if(isset($_POST['refresh'])) { 
     6    $nextquote =  $quotescollection_next_quote?$quotescollection_next_quote:__('Next quote', 'quotes-collection')."&nbsp;&raquo;"; 
     7    $loading = __('Loading...', 'quotes-collection'); 
     8    $error = __('Error getting quote', 'quotes-collection'); 
     9    $auto_refresh_max = $quotescollection_auto_refresh_max; 
    610 
    7     if (!$blogdir) { 
    8         $blogdir = preg_replace('|/wp-content.*$|','', __FILE__); 
    9     } 
    10     if($blogdir == __FILE__) { 
    11         $blogdir = preg_replace('|\wp-content.*$|','', __FILE__); 
    12         include_once($blogdir.'\wp-config.php'); 
    13         include_once($blogdir.'\wp-includes\wp-db.php'); 
    14     } 
    15     else { 
    16         include_once($blogdir.'/wp-config.php'); 
    17         include_once($blogdir.'/wp-includes/wp-db.php'); 
    18     } 
    19     include_once(str_replace("-ajax", "", __FILE__)); 
     11    wp_enqueue_script( 'quotescollection', plugin_dir_url(__FILE__).'quotes-collection.js', array('jquery') ); 
     12    wp_localize_script( 'quotescollection', 'QCAjax', array( 
     13        // URL to wp-admin/admin-ajax.php to process the request 
     14        'ajaxurl' => admin_url( 'admin-ajax.php' ), 
     15  
     16        // generate a nonce with a unique ID "myajax-post-comment-nonce" 
     17        // so that you can check it later when an AJAX request is sent 
     18        'nonce' => wp_create_nonce( 'quotescollection' ), 
     19 
     20        'nextquote' => $nextquote, 
     21        'loading' => $loading, 
     22        'error' => $error, 
     23        'auto_refresh_max' => $quotescollection_auto_refresh_max, 
     24        'auto_refresh_count' => 0 
     25        ) 
     26    ); 
     27} 
     28add_action('init', 'quotescollection_scripts'); 
     29 
     30 
     31function quotescollection_load() 
     32{ 
     33    check_ajax_referer('quotescollection');  
     34     
     35     
    2036    $show_author = isset($_POST['show_author'])?$_POST['show_author']:1; 
    2137    $show_source = isset($_POST['show_source'])?$_POST['show_source']:1; 
     
    2440    $char_limit = (isset($_POST['char_limit']) && is_numeric($_POST['char_limit']))?$_POST['char_limit']:''; 
    2541     
    26     if($random_refresh && $_POST['current'] && is_numeric($_POST['current'])) 
     42    if($random_refresh && $_POST['current'] && is_numeric($_POST['current'])) { 
    2743        $exclude = $_POST['current']; 
     44        $current = ''; 
     45    } 
    2846    else { 
    2947        if ($_POST['current'] && is_numeric($_POST['current'])) 
     
    3856 
    3957    if($response = quotescollection_quote($args)) { 
    40         @header("Content-type: text/javascript; charset=utf-8"); 
     58        @header("Content-type: text/html; charset=utf-8"); 
    4159        die( $response );  
    4260    } 
     
    4462        die( $error ); 
    4563} 
    46  
     64add_action ("wp_ajax_quotescollection", "quotescollection_load"); 
     65add_action ("wp_ajax_nopriv_quotescollection", "quotescollection_load"); 
    4766?> 
  • quotes-collection/trunk/quotes-collection.css

    r253475 r402859  
    4343} 
    4444 
     45a.disabled { 
     46    cursor:default; 
     47} 
    4548 
    4649/* See http://www.w3schools.com/css/pr_gen_quotes.asp */ 
  • quotes-collection/trunk/quotes-collection.js

    r253475 r402859  
    1 var quotcoll_requrl, quotcoll_nextquote, quotcoll_loading, quotcoll_errortext, quotcoll_auto_refresh_max; 
    2 var quotcoll_auto_refresh_count = 0; 
    3  
    4 function quotescollection_init(requrl, nextquote, loading, errortext, auto_refresh_max) 
    5 { 
    6     quotcoll_requrl = requrl; 
    7     quotcoll_nextquote = nextquote; 
    8     quotcoll_loading = loading; 
    9     quotcoll_errortext = errortext; 
    10     quotcoll_auto_refresh_max = auto_refresh_max; 
    11 } 
    12  
    131function quotescollection_timer(instance, current, show_author, show_source, filter_tags, char_limit, auto_refresh, random_refresh) 
    142{ 
    153    var time_interval = auto_refresh * 1000; 
    16     if( (quotcoll_auto_refresh_max == 0) || (quotcoll_auto_refresh_count < quotcoll_auto_refresh_max) ) { 
     4    if( (QCAjax.auto_refresh_max == 0) || (QCAjax.auto_refresh_count < QCAjax.auto_refresh_max) ) { 
    175        setTimeout("quotescollection_refresh("+instance+", "+current+", "+show_author+", "+show_source+", '"+filter_tags+"', "+char_limit+", "+auto_refresh+", "+random_refresh+")", time_interval); 
    18         quotcoll_auto_refresh_count += 1; 
     6        QCAjax.auto_refresh_count += 1; 
    197    } 
    208} 
     
    2412function quotescollection_refresh(instance, current, show_author, show_source, filter_tags, char_limit, auto_refresh, random_refresh) 
    2513{ 
    26     jQuery("#quotescollection_nextquote-"+instance).html(quotcoll_loading); 
     14    jQuery("#quotescollection_nextquote-"+instance).html(QCAjax.loading); 
    2715    jQuery.ajax({ 
    2816        type: "POST", 
    29         url: quotcoll_requrl, 
    30         data: "refresh="+instance+"&current="+current+"&show_author="+show_author+"&show_source="+show_source+"&char_limit="+char_limit+"&tags="+filter_tags+"&auto_refresh="+auto_refresh+"&random_refresh="+random_refresh, 
     17        url: QCAjax.ajaxurl, 
     18        data: "action=quotescollection&_ajax_nonce="+QCAjax.nonce+"&refresh="+instance+"&current="+current+"&show_author="+show_author+"&show_source="+show_source+"&char_limit="+char_limit+"&tags="+filter_tags+"&auto_refresh="+auto_refresh+"&random_refresh="+random_refresh, 
    3119        success: function(response) { 
    3220            jQuery("#quotescollection_randomquote-"+instance).hide(); 
     
    3523        }, 
    3624        error: function(xhr, textStatus, errorThrown) { 
    37 //          alert(textStatus+' '+xhr.status+': '+errorThrown); 
     25            console.log(textStatus+' '+xhr.status+': '+errorThrown); 
    3826            if(auto_refresh == 0) 
    39                 jQuery("#quotescollection_nextquote-"+instance).html('<a class=\"quotescollection_refresh\" style=\"cursor:pointer\" onclick=\"quotescollection_refresh('+instance+', '+exclude+', '+show_author+', '+show_source+', \''+filter_tags+'\', '+char_limit+')\">'+quotcoll_nextquote+'</a>'); 
     27                jQuery("#quotescollection_nextquote-"+instance).html('<a class=\"quotescollection_refresh\" style=\"cursor:pointer\" onclick=\"quotescollection_refresh(\''+instance+'\', \''+current+'\', \''+show_author+'\', \''+show_source+'\', \''+filter_tags+'\', \''+char_limit+'\', \'0\', \''+random_refresh+'\');\">'+QCAjax.nextquote+'</a>'); 
    4028        }    
    4129    }); 
  • quotes-collection/trunk/quotes-collection.php

    r318365 r402859  
    44Plugin URI: http://srinig.com/wordpress/plugins/quotes-collection/ 
    55Description: Quotes Collection plugin with Ajax powered Random Quote sidebar widget helps you collect and display your favourite quotes on your WordPress blog. 
     6Version: 1.5 
    67Author: Srini G 
    7 Version: 1.4.4 
    88Author URI: http://srinig.com/wordpress/ 
     9License: GPL2 
    910*/ 
    10 /*  Released under GPL: 
    11     http://wordpress.org/about/gpl/ 
     11 
     12/*  Copyright 2007-2011 Srini G (email : srinig.com@gmail.com) 
     13 
     14    This program is free software; you can redistribute it and/or modify 
     15    it under the terms of the GNU General Public License as published by 
     16    the Free Software Foundation; either version 2 of the License, or 
     17    (at your option) any later version. 
     18 
     19    This program is distributed in the hope that it will be useful, 
     20    but WITHOUT ANY WARRANTY; without even the implied warranty of 
     21    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
     22    GNU General Public License for more details. 
     23 
     24    You should have received a copy of the GNU General Public License 
     25    along with this program; if not, write to the Free Software 
     26    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA 
    1227*/ 
     28 
    1329 
    1430 
     
    2642 
    2743/*  Refer http://codex.wordpress.org/Roles_and_Capabilities */ 
    28 $quotescollection_admin_userlevel = 2;  
     44$quotescollection_admin_userlevel = 'edit_posts';  
    2945 
    3046 
     
    3248 
    3349 
    34  
     50require_once('quotes-collection-ajax.php'); 
     51require_once('quotes-collection-widget.php'); 
     52require_once('quotes-collection-admin.php'); 
     53require_once('quotes-collection-shortcodes.php'); 
    3554 
    3655function quotescollection_get_randomquote($exclude = 0) 
     
    3958    else $condition = ""; 
    4059    return quotescollection_get_quote($condition); 
     60} 
     61 
     62function quotescollection_get_quotes($condition = "") 
     63{ 
     64    global $wpdb; 
     65    $sql = "SELECT quote_id, quote, author, source, tags, public 
     66        FROM " . $wpdb->prefix . "quotescollection" 
     67        . $condition; 
     68     
     69    if($quotes = $wpdb->get_results($sql, ARRAY_A)) 
     70        return $quotes;  
     71    else 
     72        return array(); 
     73 
    4174} 
    4275 
     
    4780        FROM " . $wpdb->prefix . "quotescollection"; 
    4881    if ($condition) 
    49         $sql .= " WHERE ".$condition; 
     82        $sql .= $condition; 
    5083    if(!$random) { 
    5184        if($current) 
     
    71104{ 
    72105    global $wpdb; 
    73     if($condition) $condition = " WHERE ".$condition; 
    74106    $sql = "SELECT COUNT(*) FROM " . $wpdb->prefix . "quotescollection ".$condition; 
    75107    $count = $wpdb->get_var($sql); 
     
    77109} 
    78110 
    79 function quotescollection_js_head() 
    80 { 
    81     if ( !defined('WP_PLUGIN_URL') ) 
    82         $wp_plugin_url = get_bloginfo( 'url' )."/wp-content/plugins"; 
    83     else 
    84         $wp_plugin_url = WP_PLUGIN_URL; 
    85  
    86     global $quotescollection_auto_refresh_max, $quotescollection_next_quote; 
    87  
    88     $requrl = $wp_plugin_url . "/quotes-collection/quotes-collection-ajax.php"; 
    89     $nextquote =  $quotescollection_next_quote?$quotescollection_next_quote:__('Next quote', 'quotes-collection')."&nbsp;&raquo;"; 
    90     $loading = __('Loading...', 'quotes-collection'); 
    91     $error = __('Error getting quote', 'quotes-collection'); 
    92     $auto_refresh_max = $quotescollection_auto_refresh_max; 
    93  
    94     ?> 
    95 <!-- Quotes Collection --> 
    96 <script type="text/javascript" src="<?php echo $wp_plugin_url; ?>/quotes-collection/quotes-collection.js"></script> 
    97 <script type="text/javascript"> 
    98   quotescollection_init(<?php echo "'{$requrl}', '{$nextquote}', '{$loading}', '{$error}', '{$auto_refresh_max}'"; ?>); 
    99 </script> 
    100 <?php 
    101 } 
    102 add_action('wp_head', 'quotescollection_js_head' ); 
    103  
    104  
    105 function quotescollection_enqueue() 
    106 { 
    107     wp_enqueue_script('jquery'); 
    108 } 
    109 add_action('init', 'quotescollection_enqueue'); 
    110  
     111function quotescollection_pagenav($total, $current = 1, $format = 0, $paged = 'paged', $url = "") 
     112{ 
     113    if($total == 1 && $current == 1) return ""; 
     114     
     115    if(!$url) { 
     116        $url = 'http'; 
     117        if (isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == "on") {$url .= "s";} 
     118        $url .= "://"; 
     119        if ($_SERVER["SERVER_PORT"] != "80") { 
     120            $url .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["PHP_SELF"]; 
     121        } else { 
     122            $url .= $_SERVER["SERVER_NAME"].$_SERVER["PHP_SELF"]; 
     123        } 
     124        if($query_string = $_SERVER['QUERY_STRING']) { 
     125            $parms = explode('&', $query_string); 
     126            $y = '?'; 
     127            foreach($parms as $parm) { 
     128                $x = explode('=', $parm); 
     129                if($x[0] == $paged) { 
     130                    $query_string = str_replace($y.$parm, '', $query_string); 
     131                } 
     132                else $y = '&'; 
     133            } 
     134            if($query_string) { 
     135                $url .= '?'.$query_string; 
     136                $a = '&'; 
     137            } 
     138            else $a = '?';   
     139        } 
     140        else $a = '?'; 
     141    } 
     142    else { 
     143        $a = '?'; 
     144        if(strpos($url, '?')) $a = '&';  
     145    } 
     146     
     147    if(!$format || $format > 2 || $format < 0 || !is_numeric($format)) {     
     148        if($total <= 8) $format = 1; 
     149        else $format = 2; 
     150    } 
     151     
     152     
     153    if($current > $total) $current = $total; 
     154        $pagenav = ""; 
     155 
     156    if($format == 2) { 
     157        $first_disabled = $prev_disabled = $next_disabled = $last_disabled = ''; 
     158        if($current == 1) 
     159            $first_disabled = $prev_disabled = ' disabled'; 
     160        if($current == $total) 
     161            $next_disabled = $last_disabled = ' disabled'; 
     162 
     163        $pagenav .= "<a class=\"first-page{$first_disabled}\" title=\"".__('Go to the first page', 'quotes-collection')."\" href=\"{$url}\">&laquo;</a>&nbsp;&nbsp;"; 
     164 
     165        $pagenav .= "<a class=\"prev-page{$prev_disabled}\" title=\"".__('Go to the previous page', 'quotes-collection')."\" href=\"{$url}{$a}{$paged}=".($current - 1)."\">&#139;</a>&nbsp;&nbsp;"; 
     166 
     167        $pagenav .= '<span class="paging-input">'.$current.' of <span class="total-pages">'.$total.'</span></span>'; 
     168 
     169        $pagenav .= "&nbsp;&nbsp;<a class=\"next-page{$next_disabled}\" title=\"".__('Go to the next page', 'quotes-collection')."\" href=\"{$url}{$a}{$paged}=".($current + 1)."\">&#155;</a>"; 
     170 
     171        $pagenav .= "&nbsp;&nbsp;<a class=\"last-page{$last_disabled}\" title=\"".__('Go to the last page', 'quotes-collection')."\" href=\"{$url}{$a}{$paged}={$total}\">&raquo;</a>"; 
     172     
     173    } 
     174    else { 
     175        $pagenav = __("Goto page:", 'quotes-collection'); 
     176        for( $i = 1; $i <= $total; $i++ ) { 
     177            if($i == $current) 
     178                $pagenav .= "&nbsp<strong>{$i}</strong>"; 
     179            else if($i == 1) 
     180                $pagenav .= "&nbsp;<a href=\"{$url}\">{$i}</a>"; 
     181            else  
     182                $pagenav .= "&nbsp;<a href=\"{$url}{$a}{$paged}={$i}\">{$i}</a>"; 
     183        } 
     184    } 
     185    return $pagenav; 
     186} 
    111187 
    112188function quotescollection_txtfmt($quotedata = array()) 
     
    157233        'echo' => 1, 
    158234        'random' => 1, 
    159         'exclude' => '' 
     235        'exclude' => '', 
     236        'current' => 0 
    160237    ); 
    161238     
    162239    $options = array_merge($options_default, $options); 
    163240     
    164     $condition = "public = 'yes'"; 
     241    $condition = " WHERE public = 'yes'"; 
    165242     
    166243    if($options['random']) 
     
    178255    if($options['tags']) { 
    179256        $taglist = explode(',', $options['tags']); 
     257        $tag_condition = ""; 
    180258        foreach($taglist as $tag) { 
    181259            $tag = mysql_real_escape_string(strip_tags(trim($tag))); 
     
    193271                 
    194272    $display = "<p><q>". $random_quote['quote'] ."</q>"; 
     273    $cite = ""; 
    195274    if($options['show_author'] && $random_quote['author']) 
    196275        $cite = '<span class="quotescollection_author">'. $random_quote['author'] .'</span>'; 
     
    230309} 
    231310 
    232 function quotescollection_init() 
    233 { 
    234     if(function_exists('load_plugin_textdomain')) 
    235         load_plugin_textdomain('quotes-collection', 'wp-content/plugins/quotes-collection/languages/'); 
    236      
    237     if ( !function_exists('register_sidebar_widget') || !function_exists('register_widget_control') ) 
    238         return; 
    239      
    240     function quotescollection_widget($args) { 
    241         $options = get_option('quotescollection'); 
    242         $title = isset($options['title'])?apply_filters('the_title', $options['title']):__('Random Quote', 'quotes-collection'); 
    243         $show_author = isset($options['show_author'])?$options['show_author']:1; 
    244         $show_source = isset($options['show_source'])?$options['show_source']:1; 
    245         $ajax_refresh = isset($options['ajax_refresh'])?$options['ajax_refresh']:1; 
    246         $auto_refresh = isset($options['auto_refresh'])?$options['auto_refresh']:0; 
    247         $random_refresh = isset($options['random_refresh'])?$options['random_refresh']:1; 
    248         if($auto_refresh) 
    249             $auto_refresh = isset($options['refresh_interval'])?$options['refresh_interval']:5; 
    250         $char_limit = $options['char_limit']; 
    251         $tags = $options['tags']; 
    252         $parms = "echo=0&show_author={$show_author}&show_source={$show_source}&ajax_refresh={$ajax_refresh}&auto_refresh={$auto_refresh}&char_limit={$char_limit}&tags={$tags}&random={$random_refresh}"; 
    253         if($random_quote = quotescollection_quote($parms)) { 
    254             extract($args); 
    255             echo $before_widget; 
    256             if($title) echo $before_title . $title . $after_title . "\n"; 
    257             echo $random_quote; 
    258             echo $after_widget; 
    259         } 
    260     } 
    261      
    262     function quotescollection_widget_control() 
    263     { 
    264          
    265         // default values for options 
    266         $options = array( 
    267             'title' => __('Random Quote', 'quotes-collection'),  
    268             'show_author' => 1, 
    269             'show_source' => 0,  
    270             'ajax_refresh' => 1, 
    271             'auto_refresh' => 0, 
    272             'random_refresh' => 1, 
    273             'refresh_interval' => 5, 
    274             'tags' => '', 
    275             'char_limit' => 500 
    276         ); 
    277  
    278         if($options_saved = get_option('quotescollection')) 
    279             $options = array_merge($options, $options_saved); 
    280              
    281         // Update options in db when user updates options in the widget page 
    282         if($_REQUEST['quotescollection-submit']) {  
    283             $options['title']  
    284                 = strip_tags(stripslashes($_REQUEST['quotescollection-title'])); 
    285             $options['show_author'] = $_REQUEST['quotescollection-show_author']?1:0; 
    286             $options['show_source'] = $_REQUEST['quotescollection-show_source']?1:0; 
    287             $options['ajax_refresh'] = $_REQUEST['quotescollection-ajax_refresh']?1:0; 
    288             $options['auto_refresh'] = $_REQUEST['quotescollection-auto_refresh']?1:0; 
    289             $options['refresh_interval'] = $_REQUEST['quotescollection-refresh_interval']; 
    290             $options['random_refresh'] = $_REQUEST['quotescollection-random_refresh']?1:0; 
    291             $options['tags'] = strip_tags(stripslashes($_REQUEST['quotescollection-tags'])); 
    292             $options['char_limit'] = strip_tags(stripslashes($_REQUEST['quotescollection-char_limit'])); 
    293             if(!$options['char_limit']) 
    294                 $options['char_limit'] = __('none', 'quotes-collection'); 
    295             update_option('quotescollection', $options); 
    296         } 
    297          
    298         // Now we define the display of widget options menu 
    299         if($options['show_author']) 
    300             $show_author_checked = ' checked="checked"'; 
    301         if($options['show_source']) 
    302             $show_source_checked = ' checked="checked"'; 
    303         if($options['ajax_refresh']) 
    304             $ajax_refresh_checked = ' checked="checked"'; 
    305         if($options['auto_refresh']) 
    306             $auto_refresh_checked = ' checked="checked"'; 
    307         if($options['random_refresh']) 
    308             $random_refresh_checked = ' checked="checked"'; 
    309         $int_select[$options['refresh_interval']] = ' selected="selected"'; 
    310         echo "<p style=\"text-align:left;\"><label for=\"quotescollection-title\">".__('Title', 'quotes-collection')." </label><input class=\"widefat\" type=\"text\" id=\"quotescollection-title\" name=\"quotescollection-title\" value=\"".htmlspecialchars($options['title'], ENT_QUOTES)."\" /></p>"; 
    311         echo "<p style=\"text-align:left;\"><input type=\"checkbox\" id=\"quotescollection-show_author\" name=\"quotescollection-show_author\" value=\"1\"{$show_author_checked} /> <label for=\"quotescollection-show_author\">".__('Show author?', 'quotes-collection')."</label></p>"; 
    312         echo "<p style=\"text-align:left;\"><input type=\"checkbox\" id=\"quotescollection-show_source\" name=\"quotescollection-show_source\" value=\"1\"{$show_source_checked} /> <label for=\"quotescollection-show_source\">".__('Show source?', 'quotes-collection')."</label></p>"; 
    313         echo "<p style=\"text-align:left;\"><input type=\"checkbox\" id=\"quotescollection-ajax_refresh\" name=\"quotescollection-ajax_refresh\" value=\"1\"{$ajax_refresh_checked} /> <label for=\"quotescollection-ajax_refresh\">".__('Ajax refresh feature', 'quotes-collection')."</label></p>"; 
    314         echo "<p style=\"text-align:left;\"><small><a id=\"quotescollection-adv_key\" style=\"cursor:pointer;\" onclick=\"jQuery('div#quotescollection-adv_opts').slideToggle();\">".__('Advanced options', 'quotes-collection')." &raquo;</a></small></p>"; 
    315         echo "<div id=\"quotescollection-adv_opts\" style=\"display:none\">"; 
    316         echo "<p style=\"text-align:left;\"><input type=\"checkbox\" id=\"quotescollection-random_refresh\" name=\"quotescollection-random_refresh\" value=\"1\"{$random_refresh_checked} /> <label for=\"quotescollection-random_refresh\">".__('Random refresh', 'quotes-collection')."</label><br/><span class=\"setting-description\"><small>".__('Unchecking this will rotate quotes in the order added, latest first.', 'quotes-collection')."</small></span></p>"; 
    317         echo "<p style=\"text-align:left;\"><input type=\"checkbox\" id=\"quotescollection-auto_refresh\" name=\"quotescollection-auto_refresh\" value=\"1\"{$auto_refresh_checked} /> <label for=\"quotescollection-auto_refresh\">".__('Auto refresh', 'quotes-collection')."</label> <label for=\"quotescollection-refresh_interval\">".__('every', 'quotes-collection')."</label> <select id=\"quotescollection-refresh_interval\" name=\"quotescollection-refresh_interval\"><option{$int_select['5']}>5</option><option{$int_select['10']}>10</option><option{$int_select['15']}>15</option><option{$int_select['20']}>20</option></select> ".__('sec', 'quotes-collection')."</p>"; 
    318         echo "<p style=\"text-align:left;\"><label for=\"quotescollection-tags\">".__('Tags filter', 'quotes-collection')." </label><input class=\"widefat\" type=\"text\" id=\"quotescollection-tags\" name=\"quotescollection-tags\" value=\"".htmlspecialchars($options['tags'], ENT_QUOTES)."\" /><br/><span class=\"setting-description\"><small>".__('Comma separated', 'quotes-collection')."</small></span></p>"; 
    319         echo "<p style=\"text-align:left;\"><label for=\"quotescollection-char_limit\">".__('Character limit', 'quotes-collection')." </label><input class=\"widefat\" type=\"text\" id=\"quotescollection-char_limit\" name=\"quotescollection-char_limit\" value=\"".htmlspecialchars($options['char_limit'], ENT_QUOTES)."\" /></p>"; 
    320         echo "</div>"; 
    321         echo "<input type=\"hidden\" id=\"quotescollection-submit\" name=\"quotescollection-submit\" value=\"1\" />"; 
    322     } 
    323  
    324  
    325     register_sidebar_widget(array('Random Quote', 'widgets'), 'quotescollection_widget'); 
    326     register_widget_control('Random Quote', 'quotescollection_widget_control', 250, 350); 
    327 } 
    328  
    329  
    330 function quotescollection_admin_menu()  
    331 { 
    332     global $quotescollection_admin_userlevel; 
    333     add_menu_page('Quotes Collection', 'Quotes Collection', $quotescollection_admin_userlevel, 'quotes-collection', 'quotescollection_quotes_management'); 
    334 } 
    335  
    336 function quotescollection_addquote($quote, $author = "", $source = "", $tags = "", $public = 'yes') 
    337 { 
    338     if(!$quote) return __('Nothing added to the database.', 'quotes-collection'); 
    339     global $wpdb; 
    340     $table_name = $wpdb->prefix . "quotescollection"; 
    341     if($wpdb->get_var("SHOW TABLES LIKE '$table_name'") != $table_name)  
    342         return __('Database table not found', 'quotes-collection'); 
    343     else //Add the quote data to the database 
    344     { 
    345          
    346         $quote = stripslashes($quote); 
    347         $author = stripslashes($author);     
    348         $source = stripslashes($source);     
    349         $tags = stripslashes($tags); 
    350  
    351         $quote = "'".$wpdb->escape($quote)."'"; 
    352         $author = $author?"'".$wpdb->escape($author)."'":"NULL"; 
    353         $source = $source?"'".$wpdb->escape($source)."'":"NULL"; 
    354         $tags = explode(',', $tags); 
    355         foreach ($tags as $key => $tag) 
    356             $tags[$key] = trim($tag); 
    357         $tags = implode(',', $tags); 
    358         $tags = $tags?"'".$wpdb->escape($tags)."'":"NULL"; 
    359         if(!$public) $public = "'no'"; 
    360         else $public = "'yes'"; 
    361         $insert = "INSERT INTO " . $table_name . 
    362             "(quote, author, source, tags, public, time_added)" . 
    363             "VALUES ({$quote}, {$author}, {$source}, {$tags}, {$public}, NOW())"; 
    364         $results = $wpdb->query( $insert ); 
    365         if(FALSE === $results) 
    366             return __('There was an error in the MySQL query', 'quotes-collection'); 
    367         else 
    368             return __('Quote added', 'quotes-collection'); 
    369    } 
    370 } 
    371  
    372 function quotescollection_editquote($quote_id, $quote, $author = "", $source = "", $tags = "", $public = 'yes') 
    373 { 
    374     if(!$quote) return __('Quote not updated.', 'quotes-collection'); 
    375     if(!$quote_id) return srgq_addquote($quote, $author, $source, $public); 
    376     global $wpdb; 
    377     $table_name = $wpdb->prefix . "quotescollection"; 
    378     if($wpdb->get_var("SHOW TABLES LIKE '$table_name'") != $table_name)  
    379         return __('Database table not found', 'quotes-collection'); 
    380     else //Update database 
    381     { 
    382          
    383         $quote = stripslashes($quote); 
    384         $author = stripslashes($author);     
    385         $source = stripslashes($source);     
    386         $tags = stripslashes($tags); 
    387  
    388         $quote = "'".$wpdb->escape($quote)."'"; 
    389         $author = $author?"'".$wpdb->escape($author)."'":"NULL"; 
    390         $source = $source?"'".$wpdb->escape($source)."'":"NULL"; 
    391         $tags = explode(',', $tags); 
    392         foreach ($tags as $key => $tag) 
    393             $tags[$key] = trim($tag); 
    394         $tags = implode(',', $tags); 
    395         $tags = $tags?"'".$wpdb->escape($tags)."'":"NULL"; 
    396         if(!$public) $public = "'no'"; 
    397         else $public = "'yes'"; 
    398         $update = "UPDATE " . $table_name . " 
    399             SET quote = {$quote}, 
    400                 author = {$author}, 
    401                 source = {$source},  
    402                 tags = {$tags}, 
    403                 public = {$public},  
    404                 time_updated = NOW() 
    405             WHERE quote_id = $quote_id"; 
    406         $results = $wpdb->query( $update ); 
    407         if(FALSE === $results) 
    408             return __('There was an error in the MySQL query', 'quotes-collection');         
    409         else 
    410             return __('Changes saved', 'quotes-collection'); 
    411    } 
    412 } 
    413  
    414  
    415 function quotescollection_deletequote($quote_id) 
    416 { 
    417     if($quote_id) { 
    418         global $wpdb; 
    419         $sql = "DELETE from " . $wpdb->prefix ."quotescollection" . 
    420             " WHERE quote_id = " . $quote_id; 
    421         if(FALSE === $wpdb->query($sql)) 
    422             return __('There was an error in the MySQL query', 'quotes-collection');         
    423         else 
    424             return __('Quote deleted', 'quotes-collection'); 
    425     } 
    426     else return __('The quote cannot be deleted', 'quotes-collection'); 
    427 } 
    428  
    429 function quotescollection_getquotedata($quote_id) 
    430 { 
    431     global $wpdb; 
    432     $sql = "SELECT quote_id, quote, author, source, tags, public 
    433         FROM " . $wpdb->prefix . "quotescollection  
    434         WHERE quote_id = {$quote_id}"; 
    435     $quote_data = $wpdb->get_row($sql, ARRAY_A);     
    436     return $quote_data; 
    437 } 
    438  
    439 function quotescollection_editform($quote_id = 0) 
    440 { 
    441     $public_selected = " checked=\"checked\""; 
    442     $submit_value = __('Add Quote', 'quotes-collection'); 
    443     $form_name = "addquote"; 
    444     $action_url = get_bloginfo('wpurl')."/wp-admin/admin.php?page=quotes-collection#addnew"; 
    445  
    446     if($quote_id) { 
    447         $form_name = "editquote"; 
    448         $quote_data = quotescollection_getquotedata($quote_id); 
    449         foreach($quote_data as $key => $value) 
    450             $quote_data[$key] = $quote_data[$key]; 
    451         extract($quote_data); 
    452         $quote = htmlspecialchars($quote); 
    453         $author = htmlspecialchars($author); 
    454         $source = htmlspecialchars($source); 
    455         $tags = implode(', ', explode(',', $tags)); 
    456         $hidden_input = "<input type=\"hidden\" name=\"quote_id\" value=\"{$quote_id}\" />"; 
    457         if($public == 'no') $public_selected = ""; 
    458         $submit_value = __('Save changes', 'quotes-collection'); 
    459         $back = "<input type=\"submit\" name=\"submit\" value=\"".__('Back', 'quotes-collection')."\" />&nbsp;"; 
    460         $action_url = get_bloginfo('wpurl')."/wp-admin/admin.php?page=quotes-collection"; 
    461     } 
    462  
    463     $quote_label = __('The quote', 'quotes-collection'); 
    464     $author_label = __('Author', 'quotes-collection'); 
    465     $source_label = __('Source', 'quotes-collection'); 
    466     $tags_label = __('Tags', 'quotes-collection'); 
    467     $public_label = __('Public?', 'quotes-collection'); 
    468     $optional_text = __('optional', 'quotes-collection'); 
    469     $comma_separated_text = __('comma separated', 'quotes-collection'); 
    470      
    471  
    472     $display .=<<< EDITFORM 
    473 <form name="{$form_name}" method="post" action="{$action_url}"> 
    474     {$hidden_input} 
    475     <table class="form-table" cellpadding="5" cellspacing="2" width="100%"> 
    476         <tbody><tr class="form-field form-required"> 
    477             <th style="text-align:left;" scope="row" valign="top"><label for="quotescollection_quote">{$quote_label}</label></th> 
    478             <td><textarea id="quotescollection_quote" name="quote" rows="5" cols="50" style="width: 97%;">{$quote}</textarea></td> 
    479         </tr> 
    480         <tr class="form-field"> 
    481             <th style="text-align:left;" scope="row" valign="top"><label for="quotescollection_author">{$author_label}</label></th> 
    482             <td><input type="text" id="quotescollection_author" name="author" size="40" value="{$author}" /><br />{$optional_text}</td> 
    483         </tr> 
    484         <tr class="form-field"> 
    485             <th style="text-align:left;" scope="row" valign="top"><label for="quotescollection_source">{$source_label}</label></th> 
    486             <td><input type="text" id="quotescollection_source" name="source" size="40" value="{$source}" /><br />{$optional_text}</td> 
    487         </tr> 
    488         <tr class="form-field"> 
    489             <th style="text-align:left;" scope="row" valign="top"><label for="quotescollection_tags">{$tags_label}</label></th> 
    490             <td><input type="text" id="quotescollection_tags" name="tags" size="40" value="{$tags}" /><br />{$optional_text}, {$comma_separated_text}</small></td> 
    491         </tr> 
    492         <tr> 
    493             <th style="text-align:left;" scope="row" valign="top"><label for="quotescollection_public">{$public_label}</label></th> 
    494             <td><input type="checkbox" id="quotescollection_public" name="public"{$public_selected} /> 
    495         </tr></tbody> 
    496     </table> 
    497     <p class="submit">{$back}<input name="submit" value="{$submit_value}" type="submit" class="button button-primary" /></p> 
    498 </form> 
    499 EDITFORM; 
    500     return $display; 
    501 } 
    502  
    503 function quotescollection_changevisibility($quote_ids, $public = 'yes') 
    504 { 
    505     if(!$quote_ids) 
    506         return __('Nothing done!', 'quotes-collection'); 
    507     global $wpdb; 
    508     $sql = "UPDATE ".$wpdb->prefix."quotescollection  
    509         SET public = '".$public."', 
    510             time_updated = NOW() 
    511         WHERE quote_id IN (".implode(', ', $quote_ids).")"; 
    512     $wpdb->query($sql); 
    513     if($public == 'yes') 
    514         return __("Selected quotes made public", 'quotes-collection'); 
    515     else 
    516         return __("Selected quotes made private", 'quotes-collection'); 
    517 } 
    518  
    519 function quotescollection_bulkdelete($quote_ids) 
    520 { 
    521     if(!$quote_ids) 
    522         return __('Nothing done!', 'quotes-collection'); 
    523     global $wpdb; 
    524     $sql = "DELETE FROM ".$wpdb->prefix."quotescollection  
    525         WHERE quote_id IN (".implode(', ', $quote_ids).")"; 
    526     $wpdb->query($sql); 
    527     return __('Quote(s) deleted', 'quotes-collection'); 
    528 } 
    529  
    530  
    531  
    532 function quotescollection_quotes_management() 
    533 {    
    534     global $quotescollection_db_version; 
    535     $options = get_option('quotescollection'); 
    536     if($options['db_version'] != $quotescollection_db_version ) 
    537         quotescollection_install(); 
    538          
    539     if($_REQUEST['submit'] == __('Add Quote', 'quotes-collection')) { 
    540         extract($_REQUEST); 
    541         $msg = quotescollection_addquote($quote, $author, $source, $tags, $public); 
    542     } 
    543     else if($_REQUEST['submit'] == __('Save changes', 'quotes-collection')) { 
    544         extract($_REQUEST); 
    545         $msg = quotescollection_editquote($quote_id, $quote, $author, $source, $tags, $public); 
    546     } 
    547     else if($_REQUEST['action'] == 'editquote') { 
    548         $display .= "<div class=\"wrap\">\n<h2>Quotes Collection &raquo; ".__('Edit quote', 'quotes-collection')."</h2>"; 
    549         $display .=  quotescollection_editform($_REQUEST['id']); 
    550         $display .= "</div>"; 
    551         echo $display; 
    552         return; 
    553     } 
    554     else if($_REQUEST['action'] == 'delquote') { 
    555         $msg = quotescollection_deletequote($_REQUEST['id']); 
    556     } 
    557     else if(isset($_REQUEST['bulkaction']))  { 
    558         if($_REQUEST['bulkaction'] == __('Delete', 'quotes-collection'))  
    559             $msg = quotescollection_bulkdelete($_REQUEST['bulkcheck']); 
    560         if($_REQUEST['bulkaction'] == __('Make public', 'quotes-collection')) { 
    561             $msg = quotescollection_changevisibility($_REQUEST['bulkcheck'], 'yes'); 
    562         } 
    563         if($_REQUEST['bulkaction'] == __('Keep private', 'quotes-collection')) { 
    564             $msg = quotescollection_changevisibility($_REQUEST['bulkcheck'], 'no'); 
    565         } 
    566     } 
    567      
    568     $display .= "<div class=\"wrap\">"; 
    569      
    570     if($msg) 
    571         $display .= "<div id=\"message\" class=\"updated fade\"><p>{$msg}</p></div>"; 
    572  
    573     $display .= "<h2>Quotes Collection</h2>"; 
    574  
    575  
    576     // Get all the quotes from the database 
    577     global $wpdb; 
    578  
    579     $sql = "SELECT quote_id, quote, author, source, tags, public 
    580         FROM " . $wpdb->prefix . "quotescollection"; 
    581      
    582     if(isset($_REQUEST['orderby'])) { 
    583         $sql .= " ORDER BY " . $_REQUEST['criteria'] . " " . $_REQUEST['order']; 
    584         $option_selected[$_REQUEST['criteria']] = " selected=\"selected\""; 
    585         $option_selected[$_REQUEST['order']] = " selected=\"selected\""; 
    586     } 
    587     else { 
    588         $sql .= " ORDER BY quote_id ASC"; 
    589         $option_selected['quote_id'] = " selected=\"selected\""; 
    590         $option_selected['ASC'] = " selected=\"selected\""; 
    591     } 
    592  
    593     $quotes = $wpdb->get_results($sql); 
    594      
    595     foreach($quotes as $quote_data) { 
    596         if($alternate) $alternate = ""; 
    597         else $alternate = " class=\"alternate\""; 
    598         $quotes_list .= "<tr{$alternate}>"; 
    599         $quotes_list .= "<th scope=\"row\" class=\"check-column\"><input type=\"checkbox\" name=\"bulkcheck[]\" value=\"".$quote_data->quote_id."\" /></th>"; 
    600         $quotes_list .= "<td>" . $quote_data->quote_id . "</td>"; 
    601         $quotes_list .= "<td>" . wptexturize(nl2br($quote_data->quote)) ."</td>"; 
    602         $quotes_list .= "<td>" . $quote_data->author; 
    603         if($quote_data->author && $quote_data->source) 
    604             $quotes_list .= " / "; 
    605         $quotes_list .= $quote_data->source ."</td>"; 
    606         $quotes_list .= "<td>" . implode(', ', explode(',', $quote_data->tags)) . "</td>"; 
    607         $quotes_list .= "<td>" . $quote_data->public ."</td>"; 
    608         $quotes_list .= "<td><a href=\"" . get_bloginfo('wpurl') . "/wp-admin/admin.php?page=quotes-collection&action=editquote&amp;id=".$quote_data->quote_id."\" class=\"edit\">".__('Edit', 'quotes-collection')."</a></td> 
    609     <td><a href=\"" . get_bloginfo('wpurl'). "/wp-admin/admin.php?page=quotes-collection&action=delquote&amp;id=".$quote_data->quote_id."\" onclick=\"return confirm( '".__('Are you sure you want to delete this quote?', 'quotes-collection')."');\" class=\"delete\">".__('Delete', 'quotes-collection')."</a> </td>"; 
    610         $quotes_list .= "</tr>"; 
    611     } 
    612      
    613     if($quotes_list) { 
    614         $display .= "<p>"; 
    615     $quotes_count = quotescollection_count(); 
    616     $display .= sprintf(__ngettext('Currently, you have %d quote.', 'Currently, you have %d quotes.', $quotes_count, 'quotes-collection'), $quotes_count); 
    617     // anchor to add new quote 
    618     $display .= " (<a href=\"#addnew\"><strong>".__('Add new quote', 'quotes-collection')."</strong></a>)"; 
    619     $display .= "</p>"; 
    620  
    621         $display .= "<form id=\"quotescollection\" method=\"post\" action=\"".get_bloginfo('wpurl')."/wp-admin/admin.php?page=quotes-collection\">"; 
    622         $display .= "<div class=\"tablenav\">"; 
    623         $display .= "<div class=\"alignleft actions\">"; 
    624         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Delete', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    625         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Make public', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    626         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Keep private', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    627         $display .= "&nbsp;&nbsp;&nbsp;"; 
    628         $display .= __('Sort by: ', 'quotes-collection'); 
    629         $display .= "<select name=\"criteria\">"; 
    630         $display .= "<option value=\"quote_id\"{$option_selected['quote_id']}>".__('Quote', 'quotes-collection')." ID</option>"; 
    631         $display .= "<option value=\"quote\"{$option_selected['quote']}>".__('Quote', 'quotes-collection')."</option>"; 
    632         $display .= "<option value=\"author\"{$option_selected['author']}>".__('Author', 'quotes-collection')."</option>"; 
    633         $display .= "<option value=\"source\"{$option_selected['source']}>".__('Source', 'quotes-collection')."</option>"; 
    634         $display .= "<option value=\"time_added\"{$option_selected['time_added']}>".__('Date added', 'quotes-collection')."</option>"; 
    635         $display .= "<option value=\"time_updated\"{$option_selected['time_updated']}>".__('Date updated', 'quotes-collection')."</option>"; 
    636         $display .= "<option value=\"public\"{$option_selected['public']}>".__('Visibility', 'quotes-collection')."</option>"; 
    637         $display .= "</select>"; 
    638         $display .= "<select name=\"order\"><option{$option_selected['ASC']}>ASC</option><option{$option_selected['DESC']}>DESC</option></select>"; 
    639         $display .= "<input type=\"submit\" name=\"orderby\" value=\"".__('Go', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    640         $display .= "</div>"; 
    641         $display .= "<div class=\"clear\"></div>";   
    642         $display .= "</div>"; 
    643          
    644  
    645          
    646         $display .= "<table class=\"widefat\">"; 
    647         $display .= "<thead><tr> 
    648             <th class=\"check-column\"><input type=\"checkbox\" onclick=\"quotescollection_checkAll(document.getElementById('quotescollection'));\" /></th> 
    649             <th>ID</th><th>".__('The quote', 'quotes-collection')."</th> 
    650             <th> 
    651                 ".__('Author', 'quotes-collection')." / ".__('Source', 'quotes-collection')." 
    652             </th> 
    653             <th>".__('Tags', 'quotes-collection')."</th> 
    654             <th>".__('Public?', 'quotes-collection')."</th> 
    655             <th colspan=\"2\" style=\"text-align:center\">".__('Action', 'quotes-collection')."</th> 
    656         </tr></thead>"; 
    657         $display .= "<tbody id=\"the-list\">{$quotes_list}</tbody>"; 
    658         $display .= "</table>"; 
    659  
    660  
    661         $display .= "<div class=\"tablenav\">"; 
    662         $display .= "<div class=\"alignleft actions\">"; 
    663         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Delete', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    664         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Make public', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    665         $display .= "<input type=\"submit\" name=\"bulkaction\" value=\"".__('Keep private', 'quotes-collection')."\" class=\"button-secondary\" />"; 
    666         $display .= "</div>"; 
    667  
    668         $display .= "</div>"; 
    669         $display .= "</form>"; 
    670         $display .= "<br style=\"clear:both;\" />"; 
    671  
    672     } 
    673     else 
    674         $display .= "<p>".__('No quotes in the database', 'quotes-collection')."</p>"; 
    675  
    676  
    677  
    678     $display .= "</div>"; 
    679      
    680     $display .= "<div id=\"addnew\" class=\"wrap\">\n<h2>".__('Add new quote', 'quotes-collection')."</h2>"; 
    681     $display .= quotescollection_editform(); 
    682     $display .= "</div>"; 
    683  
    684      
    685     echo $display; 
    686  
    687 } 
    688  
    689 function quotescollection_admin_footer() 
    690 { 
    691     ?> 
    692 <script type="text/javascript"> 
    693 function quotescollection_checkAll(form) { 
    694     for (i = 0, n = form.elements.length; i < n; i++) { 
    695         if(form.elements[i].type == "checkbox" && !(form.elements[i].hasAttribute('onclick'))) { 
    696                 if(form.elements[i].checked == true) 
    697                     form.elements[i].checked = false; 
    698                 else 
    699                     form.elements[i].checked = true; 
    700         } 
    701     } 
    702 } 
    703 </script> 
    704  
    705     <?php 
    706 } 
    707  
    708 add_action('admin_footer', 'quotescollection_admin_footer'); 
     311 
    709312 
    710313function quotescollection_install() 
     
    761364 
    762365 
    763 function quotescollection_displayquote($quote_id = 0) 
    764 { 
    765     global $wpdb; 
    766     $sql = "SELECT quote_id, quote, author, source 
    767         FROM " . $wpdb->prefix . "quotescollection  
    768         WHERE public = 'yes' "; 
    769     if(!$quote_id) { 
    770         $sql .= "ORDER BY RAND() 
    771             LIMIT 1"; 
    772     } 
    773     else { 
    774         $sql .= "AND quote_id = {$quote_id}"; 
    775     } 
    776     $quote_data = $wpdb->get_row($sql, ARRAY_A); 
    777     if ( !empty($quote_data) ) { 
    778         $quote_data = quotescollection_txtfmt($quote_data); 
    779         $display = "<blockquote class=\"quotescollection\"><q>".$quote_data['quote']."</q>"; 
    780         if($quote_data['author']) 
    781             $cite = $quote_data['author']; 
    782         if($quote_data['source']) { 
    783             if($cite) $cite .= ", "; 
    784             $cite .= $quote_data['source']; 
    785         } 
    786         if($cite) $cite = " <cite>&mdash;&nbsp;{$cite}</cite>";  
    787         $display .= $cite."</blockquote>"; 
    788         return $display; 
    789     } 
    790     else 
    791         return ""; 
    792 } 
    793  
    794 function quotescollection_displayquotes($source = "") 
    795 { 
    796     global $wpdb; 
    797     $source = html_entity_decode($source); 
    798     $sql = "SELECT quote_id, quote, author, source 
    799         FROM " . $wpdb->prefix . "quotescollection  
    800         WHERE public = 'yes' "; 
    801     if(!$source) { 
    802         $sql .= "ORDER BY quote"; 
    803     } 
    804     else if($source == "Anonymous" || $source == "anonymous") { 
    805         $sql .= "AND (author IS NULL OR author = '' OR author ='Anonymous')"; 
    806     } 
    807     else { 
    808         $sql .= "AND (source = '{$source}' OR author = '{$source}')"; 
    809     } 
    810     $quotes = $wpdb->get_results($sql, ARRAY_A); 
    811     if ( !empty($quotes) ) { 
    812         foreach($quotes as $quote_data) { 
    813             $quote_data = quotescollection_txtfmt($quote_data); 
    814             $display .= "<blockquote class=\"quotescollection\"><q>".$quote_data['quote']."</q>"; 
    815             $cite = ""; 
    816             if($quote_data['author']) 
    817                 $cite = $quote_data['author']; 
    818             if($quote_data['source']) { 
    819                 if($cite) $cite .= ", "; 
    820                 $cite .= $quote_data['source']; 
    821             } 
    822             if($cite) $cite = " <cite>&mdash;&nbsp;{$cite}</cite>";  
    823             $display .= $cite."</blockquote>"; 
    824         } 
    825         return $display; 
    826     } 
    827     else 
    828         return ""; 
    829 } 
    830  
    831 function quotescollection_displayquotes_tags($tags = "") 
    832 { 
    833     global $wpdb; 
    834     $tags = html_entity_decode($tags); 
    835     if(!$tags) 
    836         return ""; 
    837     $taglist = explode(',', $tags); 
    838     foreach($taglist as $tag) { 
    839         $tag = trim($tag); 
    840         if($sql_condition) $sql_condition .= " OR "; 
    841         $sql_condition .= "tags = '{$tag}' OR tags LIKE '{$tag},%' OR tags LIKE '%,{$tag},%' OR tags LIKE '%,{$tag}'"; 
    842     } 
    843     $sql = "SELECT quote_id, quote, author, source 
    844         FROM " . $wpdb->prefix . "quotescollection  
    845         WHERE public = 'yes' AND ({$sql_condition})"; 
    846     $quotes = $wpdb->get_results($sql, ARRAY_A); 
    847     if ( !empty($quotes) ) { 
    848         foreach($quotes as $quote_data) { 
    849             $quote_data = quotescollection_txtfmt($quote_data); 
    850             $display .= "<blockquote class=\"quotescollection\"><q>".$quote_data['quote']."</q>"; 
    851             $cite = ""; 
    852             if($quote_data['author']) 
    853                 $cite = $quote_data['author']; 
    854             if($quote_data['source']) { 
    855                 if($cite) $cite .= ", "; 
    856                 $cite .= $quote_data['source']; 
    857             } 
    858             if($cite) $cite = " <cite>&mdash;&nbsp;{$cite}</cite>";  
    859             $display .= $cite."</blockquote>"; 
    860         } 
    861         return $display; 
    862     } 
    863     else 
    864         return ""; 
    865 } 
    866  
    867 function quotescollection_inpost( $text ) { 
    868   $start = strpos($text,"[quote|id="); 
    869   if ($start !== FALSE) { 
    870     $text = preg_replace( "/\[quote\|id=(\d+)\]/ie", "quotescollection_displayquote('\\1')", $text ); 
    871   } 
    872   $start = strpos($text,"[quote|random]"); 
    873   if ($start !== FALSE) { 
    874     $text = preg_replace( "/\[quote\|random\]/ie", "quotescollection_displayquote()", $text ); 
    875   } 
    876   $start = strpos($text,"[quote|all]"); 
    877   if ($start !== FALSE) { 
    878     $text = preg_replace( "/\[quote\|all\]/ie", "quotescollection_displayquotes()", $text ); 
    879   } 
    880     $start = strpos($text,"[quote|author="); 
    881     if($start !== FALSE) { 
    882         $text = preg_replace("/\[quote\|author=(.{1,})?\]/ie", "quotescollection_displayquotes(\"\\1\")", $text); 
    883     } 
    884     $start = strpos($text,"[quote|source="); 
    885     if($start !== FALSE) { 
    886         $text = preg_replace("/\[quote\|source=(.{1,})?\]/ie", "quotescollection_displayquotes(\"\\1\")", $text); 
    887     } 
    888     $start = strpos($text,"[quote|tags="); 
    889     if($start !== FALSE) { 
    890         $text = preg_replace("/\[quote\|tags=(.{1,})?\]/ie", "quotescollection_displayquotes_tags(\"\\1\")", $text); 
    891     }   return $text; 
    892 } 
    893  
    894366function quotescollection_css_head()  
    895367{ 
    896  
    897     if ( !defined('WP_PLUGIN_URL') ) 
    898         $wp_plugin_url = get_bloginfo( 'url' )."/wp-content/plugins"; 
    899     else 
    900         $wp_plugin_url = WP_PLUGIN_URL; 
    901368    ?> 
    902     <link rel="stylesheet" type="text/css" href="<?php echo $wp_plugin_url; ?>/quotes-collection/quotes-collection.css" /> 
     369    <link rel="stylesheet" type="text/css" href="<?php echo plugins_url(); ?>/quotes-collection/quotes-collection.css" /> 
    903370    <?php 
    904371} 
     
    909376 
    910377 
    911 add_filter('the_content', 'quotescollection_inpost', 7); 
    912 add_filter('the_excerpt', 'quotescollection_inpost', 7); 
    913378register_activation_hook( __FILE__, 'quotescollection_install' ); 
    914 add_action('admin_menu', 'quotescollection_admin_menu'); 
    915 add_action('plugins_loaded', 'quotescollection_init'); 
    916379?> 
  • quotes-collection/trunk/readme.txt

    r318365 r402859  
    33Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=HDWT2K8TXXHUN 
    44Tags: quotes collection, quotes, quotations, random quote, sidebar, widget, ajax 
    5 Requires at least: 2.2 
    6 Tested up to: 3.1 beta1 
     5Requires at least: 2.8 
     6Tested up to: 3.2-RC3 
    77Stable tag: trunk 
    88 
     
    1111== Description == 
    1212 
    13 Quotes Collection plugin with Ajax powered Random Quote sidebar widget helps you collect, manage and display your favourite quotations on your WordPress blog. All quotes or a set of quotes can also be displayed on a page using a `[quote]` shortcode. 
     13Quotes Collection plugin with Ajax powered Random Quote sidebar widget helps you collect, manage and display your favourite quotations on your WordPress blog. All quotes or a set of quotes can also be displayed on a page using a `[quotcoll]` shortcode. 
     14 
    1415 
    1516Features and notes: 
     
    2425    * Show only quotes with certain tags 
    2526    * Specify a character limit and filter out bigger quotes 
    26 * The template function `quotescollection_quote()` can be used to display a random quote in places other than sidebar. See [other notes](http://wordpress.org/extend/plugins/quotes-collection/other_notes/) for details. 
    27 * Quotes can be displayed in a page by placing a shortcode such as the ones below. 
    28     * Placing `[quote|all]` in the page displays all quotes. 
    29     * `[quote|author=Somebody]` displays quotes authored by Somebody. 
    30     * `[quote|source=Something]` displays quotes with source as 'Something' 
    31     * `[quote|tags=sometag]` displays quotes tagged sometag  
    32     * `[quote|tags=tag1,tag2,tag3]` displays quotes tagged tag1 or tag2 or tag3, one or more or all of these 
    33     * `[quote|id=3]` displays quote with ID 3 
    34     * `[quote|random]` displays a random quote 
     27* Quotes can be displayed in a WordPress page by placing a shortcode such as the ones below. For more examples and the full list of arguments, please refer [other notes](http://wordpress.org/extend/plugins/quotes-collection/other_notes/). *(Note: as of version 1.5, the new `[quotcoll]` shortcode is introduced which uses the WordPress shortoced API. The older `[quote]` shortcode is deprecated.)*  
     28    * Placing `[quotcoll]` in the page displays all quotes. 
     29    * `[quotcoll author="Somebody"]` displays quotes authored by Somebody. 
     30    * `[quotcoll tags="tag1,tag2,tag3"]` displays quotes tagged tag1 or tag2 or tag3, one or more or all of these 
     31    * `[quotcoll orderby="random" limit=1]` displays a random quote 
     32* To code the random quote functionality directly into a template file, the template function `quotescollection_quote()` can be used. Please refer [other notes](http://wordpress.org/extend/plugins/quotes-collection/other_notes/) for details. 
    3533* The plugin comes with a nice admin interface to add, edit and manage quotes. 
    3634* Compatible with WordPress 3.0 multi-site functionality. 
    37 * The plugin suppports localization. See [other notes](http://wordpress.org/extend/plugins/quotes-collection/other_notes/) for the full list of available languages and the respective translators.  
     35* The plugin suppports localization. Refer the plugin page or 'Other Notes' for the full list of available languages and the respective translators.  
     36 
     37For more, visit the [plugin page](http://srinig.com/wordpress/plugins/quotes-collection/). Please provide your feedback at the [WordPress support forums](http://wordpress.org/tags/quotes-collection?forum_id=10). 
    3838 
    3939== Installation == 
    40401. Upload `quotes-collection` directory to the `/wp-content/plugins/` directory 
    41411. Activate the 'Quotes Collection' plugin through the 'Plugins' menu in WordPress 
    42 1. Add and manage the quotes through the 'Quotes Collection' menu in the WordPress admin area 
     421. Add and manage the quotes through the 'Quotes' menu in the WordPress admin area 
    43431. To display a random quote in the sidebar, go to 'Widgets' menu and drag the 'Random Quote' widget into the sidebar 
    4444 
     
    5959= How to change the link text from 'Next quote »' to something else? = 
    6060 
    61 Change the value of the variable `$quotescollection_next_quote` on line 16 of the quotes-collection.php file. 
     61Change the value of the variable `$quotescollection_next_quote` on line 34 of the quotes-collection.php file. 
    6262 
    6363= The 'Next quote »' link is not working. Why? = 
     
    7676            |-- quotes-collection-ajax.php</pre> 
    7777         
    78 If you still experience the problem even after the above conditions are met, [contact](http://srinig.com/contact/) the plugin author. 
    79  
    80  
    81 = What are the parameters that can be passed on to  `quotescollection_quote()` template function? = 
    82  
    83 Please refer [other notes](http://wordpress.org/extend/plugins/quotes-collection/other_notes/) 
     78If you still experience the problem even after the above conditions are met, [contact](http://srinig.com/wordpress/contact/) the plugin author. 
    8479 
    8580= How to change the admin access level setting for the quotes collection admin page? = 
    8681 
    87 Change the value of the variable `$quotescollection_admin_userlevel` on line 26 of the quotes-collection.php file. Refer [WordPress documentation](http://codex.wordpress.org/Roles_and_Capabilities) for more information about user roles and capabilities. 
    88  
    89 = I have a long list of quotes, and `[quote|all]` puts all of the quotes in a single page. Is there a way to introduce pagination and break the long list of quotes into different pages? = 
    90  
    91 Inbuilt pagination support may be introduced in a future version. As of now, you can separate different set of quotes based on author name `[quote|author=]` or tags `[quote|tags=]` and introduce a [`<!--nextpage-->`](http://codex.wordpress.org/Styling_Page-Links) in between. 
     82Change the value of the variable `$quotescollection_admin_userlevel` on line 44 of the quotes-collection.php file. Refer [WordPress documentation](http://codex.wordpress.org/Roles_and_Capabilities) for more information about user roles and capabilities. 
     83 
     84= I have a long list of quotes, and `[quotcoll]` puts all of the quotes in a single page. Is there a way to introduce pagination and break the long list of quotes into different pages? = 
     85 
     86Yes, pagination is supporterd in versions 1.5 and greater. `paging` and `limit_per_page` attributes can be used to achieve this. For example, `[quotcoll paging=true limit_per_page=30]` will introduce pagination with a maximum of 30 quotes per page. 
    9287 
    9388= How about a feature to backup/export/import the bulk of quotes in CSV/text format? = 
     
    9792== Screenshots == 
    9893 
    99 1. Admin interface (in WordPress 3.0) 
    100 2. 'Random Quote' widget options (WordPress 3.0) 
    101 3. An example of the random quote displayed on a sidebar 
    102  
     941. Admin interface (in WordPress 3.2) 
     952. 'Random Quote' widget options (WordPress 3.2) 
     963. A random quote in the sidebar 
     97 
     98== The [quotcoll] shortcode == 
     99Quotes can be displayed in a page by placing the shortcode `[quotcoll]`. This will display all the public quotes ordered by the quote id. 
     100 
     101Different attributes can be specified to customize the way the quotes are displayed. Here's the list of attributes: 
     102 
     103* **id** *(integer)* 
     104    * For example, `[quotcoll id=3]` displays a single quote, the id of which is 3. If there is no quote with the id 3, nothing is displayed. 
     105    * This overrides all other attributes. That is, if id attribute is specified, any other attribute specified is ignored. 
     106     
     107* **author** *(string)* 
     108    * `[quotcoll author="Somebody"]` displays all quotes authored by 'Somebody'. 
     109 
     110* **source** *(string)*  
     111    * `[quotcoll source="Something"]` displays all quotes from the source 'Something'. 
     112 
     113* **tags** *(string, comma separated)*   
     114    * `[quotcoll tags="tag1"]` displays all quotes tagged 'tag1'. 
     115    * `[quotcoll tags="tag1, tag2, tag3"]` displays quotes tagged 'tag1' or 'tag2' or 'tag3', one or more or all of these. 
     116    * `[quotcoll author="Somebody" tags="tag1"]` displays quotes authored by 'Somebody' AND tagged 'tag1'. 
     117 
     118* **orderby** *(string)* 
     119    * When multiple quotes are displayed, the quotes or ordered based on this value. The value can be either of these: 
     120        * 'quote_id' (default) 
     121        * 'author' 
     122        * 'source' 
     123        * 'date_added' 
     124        * 'random' 
     125     
     126* **order** *(string)*  
     127    * The value can be either 'ASC' (default) or 'DESC', for ascending and descending order respectively. 
     128    * For example, `[quotcoll orderby="date_added" order="DESC"]` will display all the quotes in the order of date added, latest first and the earliest last. 
     129     
     130* **paging** *(boolean)* 
     131    * The values can be: 
     132        * false (or 0) (default) 
     133        * true (or 1) -- introduces paging. This is used in conjunction with `limit_per_page` (see below). 
     134    * For example, `[quotcoll paging=true limit_per_page=30]` will introduce paging with maximum of 30 quotes per page. 
     135    * Note: if `orderby="random"` is used, paging is ignored. 
     136 
     137* **limit_per_page** *(integer)* 
     138    * The maximum number of quotes to be displayed in a page when paging is introduced, as described above. 
     139    * The defualt value is 10. For example, `[quotcoll paging=true]` will introduce paging with maximum of 10 quotes per page. 
     140 
     141* **limit** *(integer)* 
     142    * The maximum number of quotes to be displayed in a single page ie., when paging is 'false'. 
     143    * This can be used, for example, to display just a random quote. `[quotcoll orderby="random" limit=1]` 
     144     
    103145== The quotescollection_quote() template function == 
    104146 
     
    175217* `hr_HR` / Croatian / [1984da](http://faks.us/) 
    176218* `hu_HU` / Hungarian / [KOOS, Tamas](http://www.koosfoto.hu/) 
     219* `id_ID` / Bahasa Indonesia / [Kelayang](http://kelayang.com/) 
    177220* `it_IT` / Italian / [Gianni Diurno  (aka gidibao)](http://gidibao.net/index.php/2008/05/26/quotes-collection-in-italiano/) 
    178221* `ja` / Japanese / [Urepko Asaba](http://sourceforge.jp/projects/wppluginsj/downloads/36796/quotes-collection%201.2.3%20Lang-ja.zip) 
     
    192235* `zh_CN` / Simplified Chinese / [天毅许](http://www.freewarecn.com/) 
    193236 
    194 You can translate the plugin in your language if it's not done already. The localization template file (quotes-collection.pot) can be found in the 'languages' folder of the plugin. After translating send the localized files to the [plugin author](http://srinig.com/contact/) so that it's included in the next update. If you are not sure how to go about translating, contact the [plugin author](http://srinig.com/contact/). 
     237You can translate the plugin in your language if it's not done already. The localization template file (quotes-collection.pot) can be found in the 'languages' folder of the plugin. After translating send the localized files to the [plugin author](http://srinig.com/wordpress/contact/) so that it's included in the next update. If you are not sure how to go about translating, contact the plugin author. 
    195238 
    196239==Changelog== 
     240* **2011-06-30: Version 1.5** 
     241    * Shortcodes revamp. The new shortcode `[quotcoll]` uses the WordPress shortcode API and comes with various options. The old `[quote]` is deprecated, but will still work as a measure of backwards compatibility. 
     242    * Ajax calls are now made to `wp-admin/admin-ajax.php`. This could potentially fix problems some websites had with the older system. 
     243    * Pagination in admin page. Other minor improvements in the admin page. 
     244    * Fixes for deprecated functions and undefined variables. Various other minor fixes and improvements. 
     245    * Bahasa Indonesia (id_ID) localization added. Tamil localization updated. 
     246    * The `.po` template file `quotes-collection.pot` is updated. New strings added, few strings have become obsolete. 
     247 
    197248* **2010-12-03: Version 1.4.4** 
    198249    * Updated Simplified Chinese localization 
     
    324375 
    325376* **2008-02-06: Version 0.9.5** 
    326     * Fixed problem with non English characters in author names while using the tag [quote|author=] 
     377    * Fixed problem with non English characters in author names while using the tag [quotcoll author=] 
    327378 
    328379* **2008-01-16: Version 0.9.4** 
     
    345396== Upgrade Notice == 
    346397 
    347 = 1.4.4 =  
    348 Upgrade if your blog is Simplified Chinese. 
     398= 1.5 =  
     399Upgrade recommended. This version comes with various fixes and improvements. 
Note: See TracChangeset for help on using the changeset viewer.