diff options
| author | Starla Insigna <hatkirby@fourisland.com> | 2009-08-09 09:14:58 -0400 |
|---|---|---|
| committer | Starla Insigna <hatkirby@fourisland.com> | 2009-08-09 09:14:58 -0400 |
| commit | 893957c41481a0cd5eb624096337762ffa54ff28 (patch) | |
| tree | 09d2487f8add5a6281e3482a471abf21faa4f819 /theme/quotes | |
| parent | d27a3784c81f0c582e43655509e806978b7e65e4 (diff) | |
| download | fourisland-893957c41481a0cd5eb624096337762ffa54ff28.tar.gz fourisland-893957c41481a0cd5eb624096337762ffa54ff28.tar.bz2 fourisland-893957c41481a0cd5eb624096337762ffa54ff28.zip | |
Created layout 7
The following changes were also made in this revision:
* All HTML was changed to XHTML and a !DOCTYPE was included to reflect this
* Rewrote quotes tracking system to be much less complicated and actually working
* Changed quotes rendering to look more like Chirpy than Rash
* Fixed comment textarea bug
* Rewrote a ton of CSS so it's not as bloated
* Added a JavaScript confirmation when deleting a comment
* AJAXified voting on the POTW
* AJAXified voting and flagging quotes
* AJAXified commenting
* AJAXified voting on posts
* Added DateFinder back after it was accidentally deleted in Layout 4.5
The following database changes must be performed as soon as possible:
* Fix title of NO <!DOCTYPE> post (the < is missing the semicolon)
* Restore post Frasty Tha Snaman from a backup
* Reset "flag" field of all rows in "rash_quotes" to 0
* Remove the "vote" and "flag" columns of "rash_tracking"
* Rename the "quote_id" column of "rash_tracking" to "vote"
The following external code changes must also be performed as soon as possible:
* Add the following line to the end of the // Four Island block in The Fourm's functions.php:
require('/svr/www/hatkirby/fourisland/main/includes/specialdates.php');
Diffstat (limited to 'theme/quotes')
| -rwxr-xr-x | theme/quotes/add.tpl | 22 | ||||
| -rwxr-xr-x | theme/quotes/browse.tpl | 92 | ||||
| -rwxr-xr-x | theme/quotes/pagenumbers.tpl | 24 | ||||
| -rwxr-xr-x | theme/quotes/search.tpl | 34 |
4 files changed, 120 insertions, 52 deletions
| diff --git a/theme/quotes/add.tpl b/theme/quotes/add.tpl index 3ae8d3b..6c45876 100755 --- a/theme/quotes/add.tpl +++ b/theme/quotes/add.tpl | |||
| @@ -1,16 +1,16 @@ | |||
| 1 | <DIV CLASS="cleardiv"></DIV> | 1 | <div class="cleardiv"></div> |
| 2 | 2 | ||
| 3 | <H1>Contribute</H1> | 3 | <h1 class="light-at-night">Contribute</h1> |
| 4 | 4 | ||
| 5 | <!--BEGIN SUBMITTED--> | 5 | <!--BEGIN SUBMITTED--> |
| 6 | <P>The quote you have submitted is:</P> | 6 | <p class="light-at-night">The quote you have submitted is:</p> |
| 7 | <P><CODE><!--SUBMITTED.QUOTE--></CODE></P> | 7 | <p class="light-at-night"><code><!--SUBMITTED.QUOTE--></code></p> |
| 8 | <P>If this is not the quote you have entered, please contact the administrator and explain your problem. | 8 | <p class="light-at-night">If this is not the quote you have entered, please contact the administrator and explain your problem. |
| 9 | Also, there is no need to press the submit button again. You're quote has already been sent.</P> | 9 | Also, there is no need to press the submit button again. You're quote has already been sent.</p> |
| 10 | <!--END SUBMITTED--> | 10 | <!--END SUBMITTED--> |
| 11 | 11 | ||
| 12 | <FORM ACTION="/quotes/add.php?submit=" METHOD="POST"> | 12 | <form action="/quotes/add.php?submit=" method="POST"> |
| 13 | <TEXTAREA COLS="80" ROWS="5" NAME="rash_quote"></TEXTAREA><BR> | 13 | <textarea cols="80" rows="5" name="rash_quote"></textarea><br /> |
| 14 | <INPUT TYPE="submit" VALUE="Add Quote!"> | 14 | <input type="submit" value="Add Quote!" /> |
| 15 | <INPUT TYPE="reset" VALUE="Reset"> | 15 | <input type="reset" value="Reset" /> |
| 16 | </FORM> | 16 | </form> |
| diff --git a/theme/quotes/browse.tpl b/theme/quotes/browse.tpl index 8726802..d710d3f 100755 --- a/theme/quotes/browse.tpl +++ b/theme/quotes/browse.tpl | |||
| @@ -1,24 +1,92 @@ | |||
| 1 | <DIV CLASS="cleardiv"></DIV> | 1 | <div class="cleardiv"></div> |
| 2 | |||
| 3 | <script type="text/javascript"> | ||
| 4 | |||
| 5 | function voteQuote(id, dir) | ||
| 6 | { | ||
| 7 | jQuery("#quote-"+id+" .quote-rating-up").addClass("quote-action-done").text("+"); | ||
| 8 | jQuery("#quote-"+id+" .quote-rating-down").addClass("quote-action-done").text("-"); | ||
| 9 | jQuery("#quote-"+id+" .quote-update-result").text("Processing...."); | ||
| 10 | jQuery.ajax({ | ||
| 11 | type: "GET", | ||
| 12 | url: "/quotes/vote.php", | ||
| 13 | data: "id="+id+"&dir="+dir, | ||
| 14 | dataType: "text", | ||
| 15 | success: function(msg) { | ||
| 16 | if (msg != "") | ||
| 17 | { | ||
| 18 | jQuery("#quote-"+id+" .quote-vote-count").text(msg); | ||
| 19 | jQuery("#quote-"+id+" .quote-update-result").text("Done"); | ||
| 20 | } else { | ||
| 21 | jQuery("#quote-"+id+" .quote-update-result").text("Error"); | ||
| 22 | } | ||
| 23 | }, | ||
| 24 | error: function() { | ||
| 25 | jQuery("#quote-"+id+" .quote-update-result").text("Error"); | ||
| 26 | } | ||
| 27 | }); | ||
| 28 | } | ||
| 29 | |||
| 30 | function flagQuote(id) | ||
| 31 | { | ||
| 32 | jQuery("#quote-"+id+" .quote-report").addClass("quote-action-done").text("[X]"); | ||
| 33 | jQuery("#quote-"+id+" .quote-update-result").text("Processing...."); | ||
| 34 | jQuery.ajax({ | ||
| 35 | type: "GET", | ||
| 36 | url: "/quotes/flag.php", | ||
| 37 | data: "id="+id, | ||
| 38 | dataType: "text", | ||
| 39 | success: function(msg) { | ||
| 40 | if (msg == "1") | ||
| 41 | { | ||
| 42 | jQuery("#quote-"+id+" .quote-update-result").text("Done"); | ||
| 43 | } else { | ||
| 44 | jQuery("#quote-"+id+" .quote-update-result").text("Error"); | ||
| 45 | } | ||
| 46 | }, | ||
| 47 | error: function() { | ||
| 48 | jQuery("#quote-"+id+" .quote-update-result").text("Error"); | ||
| 49 | } | ||
| 50 | }); | ||
| 51 | } | ||
| 52 | |||
| 53 | </script> | ||
| 2 | 54 | ||
| 3 | <!--BEGIN PAGENUMBERS--> | 55 | <!--BEGIN PAGENUMBERS--> |
| 4 | <!--INCLUDE quotes/pagenumbers--> | 56 | <!--INCLUDE quotes/pagenumbers--> |
| 5 | <!--END PAGENUMBERS--> | 57 | <!--END PAGENUMBERS--> |
| 6 | 58 | ||
| 7 | <H2><!--ORIGIN--></H2> | 59 | <h2 class="light-at-night"><!--ORIGIN--></h2> |
| 8 | 60 | ||
| 61 | <ul class="quote-list"> | ||
| 9 | <!--BEGIN QUOTES--> | 62 | <!--BEGIN QUOTES--> |
| 10 | <P> | 63 | <li id="quote-<!--QUOTES.NUMBER-->" class="quote"> |
| 11 | <A HREF="/quotes/<!--QUOTES.NUMBER-->.php">#<!--QUOTES.NUMBER--></A> | 64 | <h3 class="quote-header"> |
| 12 | <A HREF="/quotes/vote.php?id=<!--QUOTES.NUMBER-->&dir=plus">+</A> | 65 | <a class="quote-permalink" href="/quotes/<!--QUOTES.NUMBER-->.php">#<!--QUOTES.NUMBER--></a> |
| 13 | <SPAN>(<!--QUOTES.RATING-->)</SPAN> | 66 | <!--BEGIN QUOTES.CANVOTE--> |
| 14 | <A HREF="/quotes/vote.php?id=<!--QUOTES.NUMBER-->&dir=minus">-</A> | 67 | <span class="quote-rating-up"><a href="javascript:voteQuote('<!--QUOTES.NUMBER-->','plus');" rel="nofollow">+</a></span> |
| 15 | <A HREF="/quotes/flag.php?id=<!--QUOTES.NUMBER-->">[X]</A> | 68 | (<span class="quote-vote-count"><!--QUOTES.RATING--></span>) |
| 16 | 69 | <span class="quote-rating-down"><a href="javascript:voteQuote('<!--QUOTES.NUMBER-->','minus');" rel="nofollow">-</a></span> | |
| 17 | <BR> | 70 | <!--END QUOTES.CANVOTE--> |
| 71 | <!--BEGIN QUOTES.NOVOTE--> | ||
| 72 | <span class="quote-rating-up quote-action-done">+</span> | ||
| 73 | (<span class="quote-vote-count"><!--QUOTES.RATING--></span>) | ||
| 74 | <span class="quote-rating-down quote-action-done">-</span> | ||
| 75 | <!--END QUOTES.NOVOTE--> | ||
| 76 | <!--BEGIN QUOTES.CANFLAG--> | ||
| 77 | <span class="quote-report"><a href="javascript:flagQuote('<!--QUOTES.NUMBER-->');" rel="nofollow">[X]</a></span> | ||
| 78 | <!--END QUOTES.CANFLAG--> | ||
| 79 | <!--BEGIN QUOTES.NOFLAG--> | ||
| 80 | <span class="quote-report quote-action-done">[X]</span> | ||
| 81 | <!--END QUOTES.NOFLAG--> | ||
| 82 | <span class="quote-date"><!--QUOTES.DATE--></span> | ||
| 83 | <span class="quote-update-result"><!--QUOTES.COMMENTS--></span> | ||
| 84 | </h3> | ||
| 18 | 85 | ||
| 19 | <!--QUOTES.QUOTE--> | 86 | <blockquote class="quote-body"><!--QUOTES.QUOTE--></blockquote> |
| 20 | </P> | 87 | </li> |
| 21 | <!--END QUOTES--> | 88 | <!--END QUOTES--> |
| 89 | </ul> | ||
| 22 | 90 | ||
| 23 | <!--BEGIN PAGENUMBERS--> | 91 | <!--BEGIN PAGENUMBERS--> |
| 24 | <!--INCLUDE quotes/pagenumbers--> | 92 | <!--INCLUDE quotes/pagenumbers--> |
| diff --git a/theme/quotes/pagenumbers.tpl b/theme/quotes/pagenumbers.tpl index 56bedef..57533be 100755 --- a/theme/quotes/pagenumbers.tpl +++ b/theme/quotes/pagenumbers.tpl | |||
| @@ -1,17 +1,17 @@ | |||
| 1 | <DIV CLASS="cleardiv"></DIV> | 1 | <div class="cleardiv"></div> |
| 2 | 2 | ||
| 3 | <CENTER> | 3 | <center> |
| 4 | <A HREF="/quotes/<!--LORIGIN-->.php">First</A> | 4 | <a href="/quotes/<!--LORIGIN-->.php">First</a> |
| 5 | <A HREF="/quotes/<!--LORIGIN-->.php?page=<!--MINUSTEN-->">-10</A> | 5 | <a href="/quotes/<!--LORIGIN-->.php?page=<!--MINUSTEN-->">-10</a> |
| 6 | <!--BDDD--> | 6 | <span class="light-at-night"><!--BDDD--></span> |
| 7 | <!--BEGIN BPAGES--> | 7 | <!--BEGIN BPAGES--> |
| 8 | <A HREF="/quotes/<!--LORIGIN-->.php?page=<!--BPAGES.PAGENUM-->"><!--BPAGES.PAGENUM--></A> | 8 | <a href="/quotes/<!--LORIGIN-->.php?page=<!--BPAGES.PAGENUM-->"><!--BPAGES.PAGENUM--></a> |
| 9 | <!--END BPAGES--> | 9 | <!--END BPAGES--> |
| 10 | <!--CURPAGE--> | 10 | <span class="light-at-night"><!--CURPAGE--></span> |
| 11 | <!--BEGIN APAGES--> | 11 | <!--BEGIN APAGES--> |
| 12 | <A HREF="/quotes/<!--LORIGIN-->.php?page=<!--APAGES.PAGENUM-->"><!--APAGES.PAGENUM--></A> | 12 | <a href="/quotes/<!--LORIGIN-->.php?page=<!--APAGES.PAGENUM-->"><!--APAGES.PAGENUM--></a> |
| 13 | <!--END APAGES--> | 13 | <!--END APAGES--> |
| 14 | <!--ADDD--> | 14 | <span class="light-at-night"><!--ADDD--></span> |
| 15 | <A HREF="/quotes/<!--LORIGIN-->.php?page=<!--PLUSTEN-->">+10</A> | 15 | <a href="/quotes/<!--LORIGIN-->.php?page=<!--PLUSTEN-->">+10</a> |
| 16 | <A HREF="/quotes/<!--LORIGIN-->.php?page=<!--LASTPAGE-->">Last</A> | 16 | <a href="/quotes/<!--LORIGIN-->.php?page=<!--LASTPAGE-->">Last</a> |
| 17 | </CENTER> | 17 | </center> |
| diff --git a/theme/quotes/search.tpl b/theme/quotes/search.tpl index 60c0afc..6b123f4 100755 --- a/theme/quotes/search.tpl +++ b/theme/quotes/search.tpl | |||
| @@ -1,19 +1,19 @@ | |||
| 1 | <DIV CLASS="cleardiv"></DIV> | 1 | <div class="cleardiv"></div> |
| 2 | 2 | ||
| 3 | <H1>Search</H1> | 3 | <h1 class="light-at-night">Search</h1> |
| 4 | 4 | ||
| 5 | <FORM METHOD="POST" ACTION="/quotes/search.php?fetch="> | 5 | <form method="POST" action="/quotes/search.php?fetch="> |
| 6 | <INPUT TYPE="text" NAME="search" SIZE="28"> | 6 | <input type="text" name="search" size="28" /> |
| 7 | <INPUT TYPE="submit" NAME="submit"><BR> | 7 | <input type="submit" name="submit" /><br /> |
| 8 | Sort: <SELECT NAME="sortby" SIZE="1"> | 8 | <span class="light-at-night">Sort:</span> <select name="sortby" size="1"> |
| 9 | <OPTION SELECTED>Rating</OPTION> | 9 | <option selected="selected">Rating</option> |
| 10 | <OPTION>ID</OPTION> | 10 | <option>ID</option> |
| 11 | </SELECT> | 11 | </select> |
| 12 | How many: <SELECT NAME="number" SIZE="1"> | 12 | <span class="light-at-night">How many:</span> <select name="number" size="1"> |
| 13 | <OPTION SELECTED>10</OPTION> | 13 | <option selected="selected">10</option> |
| 14 | <OPTION>25</OPTION> | 14 | <option>25</option> |
| 15 | <OPTION>50</OPTION> | 15 | <option>50</option> |
| 16 | <OPTION>75</OPTION> | 16 | <option>75</option> |
| 17 | <OPTION>100</OPTION> | 17 | <option>100</option> |
| 18 | </SELECT> | 18 | </select> |
| 19 | </FORM> | 19 | </form> |
