Log In · Register

 
HELP!!!, entries...
GrayStarr
post Jun 29 2005, 06:10 PM
Post #1


yep, that's me. stop staring. :p
****

Group: Member
Posts: 257
Joined: Jun 2005
Member No: 160,969



hey um do u kno how to alternate the colors fur the entries? i checked all the help post and found 1 with alternatin the entries but alternates the date too...can u guys giv me a code to alternate the entries ONLY???
 
 
Start new topic
Replies
ckling
post Jun 29 2005, 07:52 PM
Post #2


Senior Member
****

Group: Member
Posts: 148
Joined: Jan 2005
Member No: 78,650



if(i % 2 != 0){
if(blogheaders[i].previousSibling.tagName.toLowerCase().indexOf("div")!=-1){
blogheaders[i].previousSibling.style.backgroundColor = "#404051";} /* <--- this for the odd entry's date background */
blogheaders[i].style.backgroundColor = "#404051"; /* <-- this for the odd entry's background */
blogheaders[i].nextSibling.style.backgroundColor = "#404051";
}
else{
if(blogheaders[i].previousSibling.tagName.toLowerCase().indexOf("div")!=-1){
blogheaders[i].previousSibling.style.backgroundColor = "#383849";} /*<--- this for the even entry's date background*/
blogheaders[i].style.backgroundColor = "#383849"; /* <--- this for the even entry's background*/
blogheaders[i].nextSibling.style.backgroundColor = "#383849";
}

is it better for you ??
anyway, this script work for xanga.,
test page
 

Posts in this topic


Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members: