Home
Download
Add-ons
Help
Forum
Organisation
Project
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
May 27, 2012, 02:31:11 AM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter
hier
und auf unserer
neuen Webseite
.
155555
Posts in
21715
Topics by
7737
Members
Latest Member:
gx-world
WebsiteBaker Community Forum
English
Archive (posts up to 2007)
(Moderator:
Argos
)
Random Quote Snippet/Module
Pages: [
1
]
Go Down
Author
Topic: Random Quote Snippet/Module (Read 2236 times)
Panther
Offline
Posts: 168
Random Quote Snippet/Module
«
on:
May 22, 2007, 05:08:08 AM »
Ok, I'm building a template based on my personal site at
www.upmykilt.net
I couldn't get my random quote generator to work in the template.. couldn't figure out how to get the include to work... then I remembered that the random image snippet is installed as a module.
So, I did the same thing...
Feel free to try it out. You need to edit include.php if you want to change the quotes.
I want to start looking into making this a full fledged module at some point (time permitting), that would let you enter from the admin panel the various quotes, who said it, and even edit the surrounding html tags for formatting.
But.. for now, it is what it is.
You can put this directly into a template, as I have here...
http://baker.mnpages.com/pages/templates/upmykilt.php
or put it in a code section.
Logged
Deb
Offline
Posts: 40
Re: Random Quote Snippet/Module
«
Reply #1 on:
September 05, 2007, 08:02:33 AM »
I would like to try this. Where do I upload the index.php file since it's not a module? I've never used a snippet before. Sorry to seem dumb, but I don't see uploading the quotes file or a snippet addressed in the manual. I did add a CODE section, tried pasting the index.php there and included the php code in my template and got error messages and it blew the page layout. Once I got rid of the errors, nothing showed up on the page. I do have my main setting set enable for the MANAGE SECTIONS. I'm not using an INTRO page. Sorry but I'm lost.
«
Last Edit: September 05, 2007, 08:25:15 AM by Deb
»
Logged
********************
Hope you enjoy your day!
Deb
doc
Guest
Re: Random Quote Snippet/Module
«
Reply #2 on:
September 05, 2007, 10:29:03 AM »
Hello,
all modules (no matter if snippet, admin tool or page type module) are uploaded via the WB backend: Add-ons -> Modules -> Install Module
Regards Christian
Logged
Deb
Offline
Posts: 40
Re: Random Quote Snippet/Module
«
Reply #3 on:
September 05, 2007, 12:33:59 PM »
Many thanks
I have got this working now but it's definitely not ideal since the client will want to update her own quotes and the way I got it working, she's not going to be able to. I'm wondering if I've done this right. Here is how I got it working:
Added: <div class="randomquotes"> <?php random_quotes(); ?> </div>
to my template under the content php code and uploaded the template.
Changed the quotes to my client's quotes and have had to ask the host once again to change the permissions as I'm not able to upload anything to this folder. Uploaded the changed quotes include.php.
It just seems like there must be an easier way so that the client can update her own quotes. When I added a CODE section and tried pasting in the info from the include.php I got an error msg instead. Is there a better way to do this so the client can update her own quotes?
Thanks!
Logged
********************
Hope you enjoy your day!
Deb
doc
Guest
Re: Random Quote Snippet/Module
«
Reply #4 on:
September 05, 2007, 03:50:20 PM »
Hello,
try to use the Template edit module if you want to edit textfiles contained in templates (e.g. Javascript files, PHP files, CSS files...). This way you do not run into pemission problems. Try a forum search for permissions to learn more about that topic. Files uploaded via WB should only edited via WB or WB modules, files uploaded via FTP only via FTP. If you mix both, you run into the problems you have currently.
Regards Christian
Logged
Deb
Offline
Posts: 40
Re: Random Quote Snippet/Module
«
Reply #5 on:
September 05, 2007, 04:16:50 PM »
I just added this module on, however it only gives me the option to edit my templates/css and that isn't the problem. The regular pages on my site validate, the ones that don't are the Image Gallery, the Site Map and the Download Gallery. I cannot find/access templates for these. One problem is a missing <td> tag, another is the form tags. These things are somewhere in some file that I don't know what they are named or where to find them.
Someone mentioned somewhere to try the Hello World module, but that's for making modules. I wouldn't ever attempt that - don't have the smarts for it! LOL!
The only file I've uploaded via FTP is the Random Quotes include.php and that's working fine and it's validating.
I'm open to any other suggestion, thanks!
Logged
********************
Hope you enjoy your day!
Deb
doc
Guest
Re: Random Quote Snippet/Module
«
Reply #6 on:
September 05, 2007, 04:41:12 PM »
Hello,
most of the old modules does not create valid (X)HTML as they include the stylesheet definitions into the <body> which is no longer supported (e.g. strict ...). If you want/need to fix problems with modules, the view.php file should be your first option. This file creates the output for the frontend. Unfortunatelly there is no official tool to edit module files (there is a module posted in the forum, but you need to search for). So download the module from the Addons Repository, change it locally, zip it again and install them again via the WB backend. This requires some knowledge of PHP.
Regards Christian
«
Last Edit: September 05, 2007, 04:43:12 PM by doc
»
Logged
gillweb
Offline
Posts: 83
Re: Random Quote Snippet/Module
«
Reply #7 on:
December 02, 2007, 04:54:07 AM »
Thanks Panther was looking for something like this...
Logged
Luckyluke
Offline
Posts: 555
Re: Random Quote Snippet/Module
«
Reply #8 on:
December 02, 2007, 10:44:25 AM »
Hoi,
Didn't we found something on
http://forum.websitebaker.org/index.php/topic,7923.0.html
? Or am I wrong?
Grtz,
Luckyluke
Logged
gillweb
Offline
Posts: 83
Re: Random Quote Snippet/Module
«
Reply #9 on:
December 02, 2007, 03:54:58 PM »
The quotation mod is a random quote inside a page. This puts a random quote in you template! Again, thanks Panther
Logged
Pages: [
1
]
Go Up
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> General Announcements
=> Security Announcements
=> Documentation
=> WebsiteBaker Website Showcase
=> Guest Area & Off-Topic
-----------------------------
English
-----------------------------
=> WebsiteBaker 2.9
===> Announcements
===> Help/Support
=====> Modules / Extensions
===> Suggestions
===> Software bugs
=> Help & Support
=> Modules
=> Droplets (PHP code for use with Droplet module) & Snippets (raw PHP code)
=> jQuery
=> Templates, Menus & Design
=> WebsiteBaker Language Files
=> WebsiteBaker 2.x discussion
=> WebsiteBaker 3
=> Archive (posts up to 2007)
-----------------------------
Deutsch (German)
-----------------------------
=> Ankündigungen
=> WebsiteBaker 2.9
===> Ankündigungen
===> Hilfe/Support
=====> Module / Extensions
===> Vorschläge
===> Softwarefehler
===> Erfahrungs und Testberichte
=> Hilfe/Support
=> Module & Snippets
=> Templates & Design
=> Tutorials
=> jQuery
=> Diskussion über WB
=> Off-Topic
=> Archiv für Themen bis 2007
-----------------------------
Nederlands (Dutch)
-----------------------------
=> Aankondigingen
=> Hulp & Ondersteuning
=> Niet-Terzake (Off Topic)
-----------------------------
Francais (French)
-----------------------------
=> Help/Support
-----------------------------
Italiano (Italian)
-----------------------------
=> Help/Support
-----------------------------
Bakery (WB shop module)
-----------------------------
=> Bakery English
=> Bakery Deutsch
-----------------------------
KeepInTouch (Multi Contact Module)
-----------------------------
=> KeepInTouch English
=> KeepInTouch Deutsch
Loading...