Author Topic: New FAQ Page  (Read 7973 times)

0 Members and 1 Guest are viewing this topic.

Offline batz

  • Newbie
  • *
  • Posts: 14
    • View Profile
New FAQ Page
« on: April 05, 2003, 05:54:53 PM »
Hi,

How can i make a FAQ using the same template of the 4images?
Something like when you click the register button it opens a page with the terms of registration, i want to do the same thin but with a FAQ.

Thanks
Paulo

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
New FAQ Page
« Reply #1 on: April 05, 2003, 08:07:08 PM »
the easiest way to do is using member.php file.
open it and find:
Code: [Select]
//-----------------------------------------------------
//--- Clickstream -------------------------------------
//-----------------------------------------------------

add before:
Code: [Select]
//--------------------
//---- FAQ -----------
//--------------------
if ($action == "faq") {
  $txt_clickstream = $lang['faq'];
  $site_template->register_vars(array(
    "lang_faq" => $lang['faq'],
    "lang_faq_text" => format_text($lang['faq_text'])
  ));
  $content = $site_template->parse_template("member_faq");
}
//---- End FAQ -------


then, open /lang/<yourlanguage>/main.php
at the end of the file, just before closing ?> add this:
Code: [Select]
//-----FAQ----------
$lang['faq'] = "FAQ";
$lang['faq_text'] = "Q: blah blah blah
A: blah blah blah

Q: blah2 blah2 blah2
A: blah2 blah2 blah2";
//-----End FAQ------


then, create new template and name it member_faq.html with this code:
Code: [Select]
<table width="100%" border="0" cellspacing="0" cellpadding="1">
  <tr>
    <td valign="top" class="head1">
      <table width="100%" border="0" cellpadding="4" cellspacing="0">
        <tr>
          <td valign="top" class="head1">{lang_faq}</td>
        </tr>
        <tr>
          <td class="row2">{lang_faq_text}</td>
        </tr>
      </table>
    </td>
  </tr>
</table>

save it in: /templates/<yourtemplate>/ folder.

then use this url format:
(http://yourdomain.com/4images/member.php?action=faq)

P.S. u can use BBCode ;)
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
New FAQ Page
« Reply #2 on: April 05, 2003, 08:26:06 PM »
I don't think Paulo was looking for something that specific.  To add a new template is very simple.

1.  Copy one of the existing 4images templates like error.html to FAQ.html
2.  Remove the {lang_error} {error_msg} from FAQ.html
3.  Add your FAQ information

Then just link to it using:
http://www.domain.com/4images/index.php?template=FAQ

That's it.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
New FAQ Page
« Reply #3 on: April 05, 2003, 08:55:25 PM »
ah...now I got it how it works!
I saw u posted so many times something like that...but it never worked for me...but my problem was that I was trying use different template set, not a single template...
thx, Chris ;)
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
New FAQ Page
« Reply #4 on: April 06, 2003, 02:16:21 AM »
Quote from: V@no
I saw u posted so many times something like that...

Yep, I think you're right so I'm going to add this to the FAQ forum right now.

Offline batz

  • Newbie
  • *
  • Posts: 14
    • View Profile
New FAQ Page
« Reply #5 on: April 06, 2003, 04:15:42 AM »
Many thanks to Chris and V@ano.

Glad to know that you add this feature to the FAQ.


Paulo
http://www.fotospm.com

Offline pierse

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: New FAQ Page
« Reply #6 on: June 13, 2005, 04:29:08 PM »
I don't think Paulo was looking for something that specific.  To add a new template is very simple.

1.  Copy one of the existing 4images templates like error.html to FAQ.html
2.  Remove the {lang_error} {error_msg} from FAQ.html
3.  Add your FAQ information

Then just link to it using:
http://www.domain.com/4images/index.php?template=FAQ

That's it.

Works like a charm! Thanks!