Go Back   Pligg CMS Forum > Pligg Development > Pligg Templates > Template Support

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-30-2006, 02:35 PM
Constant Pligger
 
Join Date: Jan 2006
Posts: 197
Thanks: 1
Thanked 0 Times in 0 Posts
what is the code that does vote update

the code for the update of the votecount (in ajax) I want the background to change of the link_summary votebox when i click vote.

so far, I made a new IF statement in the link_summary template, and a new ID in the css file, I got everything working, the "number of votes" has a different background then "voted on numbers"

i changed it to:
Code:
	<ul class="news-shakeit">
			
			{if $link_shakebox_currentuser_votes eq 0}
				<li class="mnm-count" id="main{$link_id}"><a href="javascript:{$link_shakebox_javascript_vote}" id="mnms-{$link_shakebox_index}">{$link_shakebox_votes} {#PLIGG_Visual_Votes#}</a>
			{else}
				<li class="mnm-count2" id="main{$link_id}"><a class="temp" id="mnms-{$link_shakebox_index}">{$link_shakebox_votes} {#PLIGG_Visual_Votes#}</a>
			{/if}
			</li>
			<li class="menealo" id="mnmlink-{$link_shakebox_index}">
			
			{if $link_shakebox_currentuser_votes eq 0}
					<a href="javascript:{$link_shakebox_javascript_vote}">{#PLIGG_Visual_Vote_For_It#}</a></li>
			{else}
					<span>{#PLIGG_Visual_Vote_Cast#}</span>
			{/if}
			
		</ul>
and added a new CSS entry (mnm-count2)

HOEVER. ONLY ON PAGELOAD are they differenciated. when I click VOTE, it does NOT change the class. how can i change that? where is the javascript? I looked in the js folder, but there is none (other then the xml one)
Reply With Quote
  #2 (permalink)  
Old 01-30-2006, 03:16 PM
Constant Pligger
 
Join Date: Jan 2006
Posts: 197
Thanks: 1
Thanked 0 Times in 0 Posts
AGHHHHH!!!! I got so close then broke it again!

I got it to change the background on the lower part, no problem. (shoulda dont that first) THEn, the top was working 100% fine, EXEPT for on loads (on load would not have the a:first-line sized properly) and now its broken again

IS there a way to delay the changing of the votecount? if it has 3 votes, and i vote, it updates to 4 right away, is there a way to update to 4 about half a second AFTER clicking vote?
Reply With Quote
Reply

Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
External Vote Button (EVB) Yankidank Modification Tutorials 59 07-24-2008 07:51 PM
Licensing tbronson Wiki Articles 0 10-27-2007 11:55 PM
Vote Code Iceburg Bug Report 1 08-06-2007 02:03 AM
Problem : voting no update the vote lucalo General Help 10 07-20-2007 12:56 PM


Search Engine Friendly URLs by vBSEO 3.2.0