Author |
Message |
finalheaven
Regular
![Regular Regular](modules/Forums/images/ranks/2stars.gif)
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Jul 15, 2006
Posts: 64
|
Posted:
Sun Jul 23, 2006 11:32 am |
|
Let me explain what I'm aiming for, and someone can suggest a proper way to do it.
Much like the News stories will list down the center of the page (and leave the margin blocks alone), or as the Forums will take up the center of the page (and also leave blocks alone), I would like to create a center page that loads a list of jpgs I'll be adding to and removing myself.
Would this just be considered new content?
Ultimately, I'd like to create a link in the Modules section (where it says Surveys Member list Forums, etc.), that says, in our case, Downed Bosses, that will link to a center page that shows a list of small jpgs. I also want to be able to update it regularly.
How should I accomplish this? Any suggestions on a Block? or module? Or just plain html/php?
Thanks a bunch. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
fkelly
Former Moderator in Good Standing
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Aug 30, 2005
Posts: 3312
Location: near Albany NY
|
Posted:
Sun Jul 23, 2006 2:48 pm |
|
To get started, I would suggest that you experiment with blocks administration. News does not have to be the block that's loaded in the center of the home page ... you could have that be content and then create a bunch of content items that each load a jpg. The messages, I believe, will automatically load at the center top of your home page but you can deactivate those. (Worth noting: what loads in home is determined in modules administration so you'd need to adjust that).
If you want something to show up in the modules area on the left side of the page (where traditionally the modules block goes (but again it doesn't have to)) you would need to create a module for it.
I believe that in the blocks administration you can even give a custom name to a block, so if you wanted you could rename content to "downed bosses" and it should work. I haven't tested that though. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kguske
Site Admin
![](modules/Forums/images/avatars/41f0b40a419280935f3a0.gif)
Joined: Jun 04, 2004
Posts: 6437
|
Posted:
Sun Jul 23, 2006 3:02 pm |
|
As fkelly mentioned, you could also do it with a message, unless you need php, then you'd need a block.
If you want even more control, take a look at NSN Center Blocks from Nukescripts.net. |
_________________ I search, therefore I exist...
Only registered users can see links on this board! Get registered or login! |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 9:42 am |
|
Let me clarify exactly what I'm trying to do:
For the normal user, the Modules Block with all the standard Module links is on the left side. Amongst those links, I would like to add a link (Downed bosses, Kill Sheet, etc.). When you click on the link, it loads in the center frame content that I would design (basically a list of mug shot pics, whatever, that I'll update frequently).
Much in the same way that if you're on the homepage, and you click Forums, it will load the forums in the center frame.
Yes, I'm dumb. ![Smile](modules/Forums/images/smiles/icon_smile.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
gregexp
The Mouse Is Extension Of Arm
![](modules/Forums/images/avatars/458c161744a70db912a6e.jpg)
Joined: Feb 21, 2006
Posts: 1497
Location: In front of a screen....HELP! lol
|
Posted:
Thu Jul 27, 2006 11:51 am |
|
No your not dumb.
This probably confused people when you first posted, almost like you wanted iframes and targets.
Now That you have clarified it, you will need to make a module and then activate it from the admin panel. |
_________________ For those who stand shall NEVER fall and those who fall shall RISE once more!! |
|
![ICQ Number ICQ Number](themes/RavenIce/forums/images/lang_english/icon_icq_add.gif) |
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 1:01 pm |
|
darklord wrote: | No your not dumb.
This probably confused people when you first posted, almost like you wanted iframes and targets.
Now That you have clarified it, you will need to make a module and then activate it from the admin panel. |
Ok, that's what I'll do then.
For the moment, I winged by activating the Content Module, and changing the name to Photo Galleries. Then I just created some mock pages. This works for now, but ultimately, by creating my own module, I'll be able to get rid of the extra click, and have two choices in the Module Menu: Downed Bosses, Member's Gallery
You can view it yourself: http://www.worldofrsa.com
lol, stumbling along... |
Last edited by finalheaven on Thu Jul 27, 2006 2:40 pm; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kguske
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 1:07 pm |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 2:42 pm |
|
If I have a javascript that I want to use on a content page, and the javascript requires I load something in the <head> tags first, where would I put that in the content page? I know content pages use html, but would I just use head tags in whatever content page I was creating? Or should I go server side, and actually add it to a particular index page?
The code I need to add is in html btw. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kguske
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 3:13 pm |
|
You would need to add that to your includes/javascript.php file, but you would probably want to conditionally load that only in the content module. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jul 27, 2006 4:23 pm |
|
kguske wrote: | You would need to add that to your includes/javascript.php file, but you would probably want to conditionally load that only in the content module. |
and how would I do that? ![Very Happy](modules/Forums/images/smiles/icon_biggrin.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
Site Admin
![](modules/Forums/images/avatars/0c0adf824792d6d341ef4.gif)
Joined: Aug 29, 2004
Posts: 9457
Location: Arizona
|
Posted:
Fri Jul 28, 2006 6:54 am |
|
try:
if ($module_name == "Content") {
<<your echo statements for your javascript go here>>
}
NOTE: if that doesn't work (i.e., it doesn't get into your code), you may need the following line above it:
global $module_name; |
_________________ Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Jul 28, 2006 8:55 am |
|
montego wrote: | try:
if ($module_name == "Content") {
<<your echo statements for your javascript go here>>
}
NOTE: if that doesn't work (i.e., it doesn't get into your code), you may need the following line above it:
global $module_name; |
Adding this broke my site (IE loaded blank pages):
Code:
if ($module_name == "Content") {
echo "<SCR IPT LANGUAGE="JavaScript">\n";
echo "<!-- Original: Ricocheting (ricocheting@hotmail.com) -->\n";
echo "<!-- Web Site: http://www.ricocheting.com -->\n";
echo "<!-- This script and many more are available free online at -->\n";
echo "<!-- The JavaScript Source!! http://javascript.internet.com -->\n";
echo "<!-- Begin\n";
echo "var rotate_delay = 5000; // delay in milliseconds (5000 = 5 secs)\n";
echo "current = 0;\n";
echo "function next() {\n";
echo "if (document.slideform.slide[current+1]) {\n";
echo "document.images.show.src = document.slideform.slide[current+1].value;\n";
echo "document.slideform.slide.selectedIndex = ++current;\n";
echo " }\n";
echo "else first();\n";
echo "}\n";
echo "function previous() {\n";
echo "if (current-1 >= 0) {\n";
echo "document.images.show.src = document.slideform.slide[current-1].value;\n";
echo "document.slideform.slide.selectedIndex = --current;\n";
echo " }\n";
echo "else last();\n";
echo "}\n";
echo "function first() {\n";
echo "current = 0;\n";
echo "document.images.show.src = document.slideform.slide[0].value;\n";
echo "document.slideform.slide.selectedIndex = 0;\n";
echo "}\n";
echo "function last() {\n";
echo "current = document.slideform.slide.length-1;\n";
echo "document.images.show.src = document.slideform.slide[current].value;\n";
echo "document.slideform.slide.selectedIndex = current;\n";
echo "}\n";
echo "function ap(text) {\n";
echo "document.slideform.slidebutton.value = (text == "Stop") ? "Start" : "Stop";\n";
echo "rotate();\n";
echo "}\n";
echo "function change() {\n";
echo "current = document.slideform.slide.selectedIndex;\n";
echo "document.images.show.src = document.slideform.slide[current].value;\n";
echo "}\n";
echo "function rotate() {\n";
echo "if (document.slideform.slidebutton.value == "Stop") {\n";
echo "current = (current == document.slideform.slide.length-1) ? 0 : current+1;\n";
echo "document.images.show.src = document.slideform.slide[current].value;\n";
echo "document.slideform.slide.selectedIndex = current;\n";
echo "window.setTimeout("rotate()", rotate_delay);\n";
echo " }\n";
echo "}\n";
echo "// End -->\n";
echo "</scr ipt>\n";
}
|
EDIT: Nope. Nevermind. The header test section of the Content page doesn't work like the <HE AD> tags in html. Ok, so yeah, I still need help getting that java code to load somewhere. Thanks. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Jul 29, 2006 6:52 am |
|
In looking at your code, you are getting parse errors because if you have double quotes inside of a double-quoted string definition, the inner quote need to be escaped. One example of this I see is this line here:
echo "<SCR IPT LANGUAGE="JavaScript">\n";
This should be:
echo "<SCR IPT LANGUAGE=\"JavaScript\">\n";
Blank pages are almost always parse errors. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
finalheaven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Jul 29, 2006 2:23 pm |
|
Yeah, I ended up getting it working using echo <<<_JS_
the code
And then
_JS_;
or some junk. I say it used somewhere else, so I gave it a try. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Jul 29, 2006 2:32 pm |
|
Yes, that method of string assignment is called HEREDOC for future reference or if you want to research it further. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
|