Posts

Showing posts with the label javascript

XSS on maxgames.com

Image
I got bored tonite... found and try these (actually noted by a friend)... XSS on maxgames.com XSS means Cross Site Scripting . Be careful if your site having these vulnerabilities. Update: one more maxgames site got xss too... maxgames.com.my it is maxis hotlink's maxgames site... * credit to z4w3p for the alert... hehehe

How to Show and Hide Text in Blog Post with teaser

Image
As my reply to Andrea's question in the comment section of my previous post on How to Show and Hide Text in Blog Post , Here is how to show and hide text in blog post with something like 300 words teaser before the link to read the rest of the story... Click here to read more... This post is already the example to show that it is possible to use the same technique in my previous show/hide blog post article to have a teaser before the link to show the rest of the story. What I've done here is just placing the "span" tags at the right position where i wanted it to be. To make it short and clear, here is the sample template to this kind of blog post... --- Place your 300 words teaser here --- <span class="postshown" id="your-topic-link-id-0001"> <a href="javascript:expandcollapse('your-topic-link-id-0001'); expandcollapse('your-topic-id-0001');"> Click here for more...</a></span> <span class="...

How to Show and Hide Text in Blog Post

Image
I would like to share on how to make a Show/Hide text in your blog post. I'm sorry if I didn't explain detail enough because I want to keep my post short as I'm in a hurry. However, you can read the detail explanation on Blogger Help . In this example, I assume you have sub topics that you want to make it hidden until reader clicks on the headline. Without the show/hide trick, it would look like this... Title One This is the example text for title one. Title Two This is the example text for title two. Title Three This is the example text for title three. Here's my step to do this... Firstly, edit your template and add the following code in the CSS area. .posthidden {display:none} .postshown {display:inline} Then add the following javascript code on your blog template between the <head></head> tag. <script type="text/Javascript"> function expandcollapse (postid) { whichpost = document.getElementById(postid); if (w...