Simple Machine Codes
March 28, 2024, 03:45:04 am
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to SMC, the best place for your SMF For Free Codes
 
  Home Help Search Arcade Gallery Affiliates Code Index Staff List Calendar Members Login Register  

Certain Image on a Certain Page

Pages: [1]   Go Down
  Print  
Author Topic: Certain Image on a Certain Page  (Read 382 times)
0 Members and 1 Guest are viewing this topic.
Agent Moose
Administrator

Offline Offline

Gender: Male
Posts: 2,672



View Profile WWW
« on: May 30, 2009, 08:59:20 pm »

Headers:
Code:
<script type="text/javascript">
function CertainBanner(tab,img){ if(location.href.match("action=" + tab)) document.write("<center><img src='" + img + "' /></center>"); };
CertainBanner("SECTION","URL");
</script>
Original Request: http://www.smfsupport.com/support/code_requests/request_certain_banners_for_certain_pages-t27113.0.html

SECTION = The page you want the image to show
To get the SECTION part, click on one of the tabs and look in the URL for the red part:
Quote
?action=forum

That would be the part you need to put in the SECTION part of the code.

URL = The URL of the image.

Here is an example of how to edit the code:
Code:
CertainBanner("admin","http://i56.photobucket.com/albums/g188/yort124/lick.gif");
The SECTION part is "admin", which I got from "?action=admin", meaning that the image specified would only appear on the admin section of the forum.

Enjoy Smiley
« Last Edit: May 30, 2009, 08:59:28 pm by Agent Moose » Report Spam   Logged

Share on Facebook Share on Twitter



Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Bookmark this site! | Upgrade This Forum
SMF For Free - Create your own Forum

Powered by SMF | SMF © 2016, Simple Machines
Privacy Policy