Author Topic: SOLVED: Question about third party script  (Read 4501 times)

0 Members and 1 Guest are viewing this topic.

Offline Jenn

  • Full Member
  • ***
  • Posts: 105
    • View Profile
SOLVED: Question about third party script
« on: February 23, 2007, 06:55:02 PM »
I was wondering if anyone could help me.

I am trying to install a third party php script with 4images.

I'm wondering if there is a conflict with it using the index.php?template= way

It's a 3 file script. I have the first two files working but the output of the third file is not looking for the "type" field.

I know I make no sense, but I have included the php files if anyone would like to take a looksee at it for me.
It works not using the above method but I would really like to integrate it into the index.php


Code: [Select]
http://download.yousendit.com/A257F27800144082
Thanks
Jen
« Last Edit: March 01, 2007, 06:34:08 PM by Jenn »

Offline BartAfterDark

  • Hero Member
  • *****
  • Posts: 520
    • View Profile
Re: Question about third party script
« Reply #1 on: February 25, 2007, 09:34:54 PM »
Do you have a link to your site?

And what are you trying to do, did you make a template inside your template folder with the script in or how?

Offline Jenn

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: Question about third party script
« Reply #2 on: February 26, 2007, 01:04:23 PM »
Here is a link.
http://www.hellonturf.com/4image/index.php?template=glitter-word-generator

I inserted script inside the template accordingly.

Here is the template code
Code: [Select]
{header}
<table width="740" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
    <td>
      <table width="640" border="0" cellspacing="0" cellpadding="0" class="tablehead">
        <tr>
          <td colspan="4"><img src="{template_url}/images/header_top.gif" width="740" height="6" alt="" /></td>
        </tr>
        <tr>
          <td width="6"><img src="{template_url}/images/header_left.gif" width="6" height="60" alt="" /></td>
          <td width="405"><img src="{template_url}/images/header_logo.gif" width="405" height="60" alt="" /></td>
          <td width="225" align="right">
            <form method="post" action="{url_search}">
              <table border="0" cellspacing="0" cellpadding="1">
                <tr>
                  <td>
                    <input type="text" name="search_keywords" size="15" class="searchinput" />
                  </td>
                  <td>
                    <input type="submit" value="{lang_search}" class="button" name="submit" />
                  </td>
                </tr>
                <tr valign="top">
                  <td colspan="2"><a href="{url_search}" class="smalltext">{lang_advanced_search}</a></td>
                </tr>
              </table>
            </form>
          </td>
          <td align="right" width="6"><img src="{template_url}/images/header_right.gif" width="6" height="60" alt="" /></td>
        </tr>
      </table>
    </td>
  </tr>
  <tr>
    <td class="bordercolor">
      <table width="740" border="0" cellspacing="1" cellpadding="0">
        <tr>
          <td class="tablebgcolor">
            <table width="638" border="0" cellspacing="1" cellpadding="0">
              <tr>
                <td height="23" class="navbar">
                  <table width="736" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td><img src="{template_url}/images/spacer.gif" width="4" height="4" alt="" />{clickstream}</td>
                      <td align="right">
<a href="{url_top_images}"><b>{lang_top_images}</b></a>&nbsp;
          <a href="{url_new_images}"><b>{lang_new_images}</b></a>&nbsp;
</td>
                    </tr>
                  </table>
                </td>
              </tr>
            </table>
            <table width="638" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="150" valign="top" class="row2">
                  <table width="150" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td class="head2" height="20"><img src="{template_url}/images/spacer.gif" alt="" width="4" height="4" />{lang_registered_user}</td>
                    </tr>
                    <tr>
                      <td class="tablebgcolor"><img src="{template_url}/images/spacer.gif" alt="" width="1" height="1" /></td>
                    </tr>
                    <tr>
                      <td align="center" class="row1">{user_box} </td>
                    </tr>
                    <tr>
                      <td class="tablebgcolor"><img src="{template_url}/images/spacer.gif" alt="" width="1" height="1" /></td>
                    </tr>
                  </table>
                  {if random_image}
                  <table width="150" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td class="head2" height="20"> <img src="{template_url}/images/spacer.gif" alt="" width="4" height="4" />{lang_random_image}</td>
                    </tr>
                    <tr>
                      <td class="tablebgcolor"><img src="{template_url}/images/spacer.gif" alt="" width="1" height="1" /></td>
                    </tr>
                    <tr>
                      <td align="center" class="row1">
    <br />
                        {random_image}
<br />
                        <br />
                      </td>
                    </tr>
                    <tr>
                      <td class="tablebgcolor"><img src="{template_url}/images/spacer.gif" alt="" width="1" height="1" /></td>
                    </tr>
                  </table>
                  {endif random_image}
                </td>
                <td width="1" class="bordercolor" valign="top"><img src="{template_url}/images/spacer.gif" width="1" height="1" alt="" /></td>
                <td width="18" valign="top"><img src="{template_url}/images/spacer.gif" width="18" height="18" alt="" /></td>
                <td width="450" valign="top">
<?php
include($_SERVER['DOCUMENT_ROOT']."/4image/gen/glitter-word-code.php");
?>

<br />
                  <table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td>{category_dropdown_form}</td>
                      <td align="right">{setperpage_dropdown_form}</td>
                    </tr>
                  </table>
                  <p>&nbsp;</p>
                </td>
                <td width="20" valign="top"><img src="{template_url}/images/spacer.gif" width="19" height="19" alt="" /></td>
              </tr>
            </table>
          </td>
        </tr>
      </table>
    </td>
  </tr>
  <tr>
    <td>
      <table width="740" border="0" cellspacing="0" cellpadding="0" class="tablebottom">
        <tr>
          <td width="6"><img src="{template_url}/images/footer_left.gif" width="6" height="19" alt="" /></td>
          <td width="405">&nbsp;</td>
          <td width="225">&nbsp;</td>
          <td width="6"><img src="{template_url}/images/footer_right.gif" width="6" height="19" alt="" /></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
{footer}

Here is the PHP code for the file that calls on the submit button
Code: [Select]
<?php $title "Myspace Glitter Word Generator";
?>

<div id="content">
<div id="titlebox">
<h1>Myspace Glitter Word Generator</h1>
</div>
<div id="pagebox">
<?
$type = $_REQUEST["type"];
?>
<table border="0" cellspacing="0" cellpadding="4" width="100%" align="center">
<form action="/4image/index.php?template=glitter-word-code?type=<? echo $type ?>" method="post">
<input type="hidden" name="action" value="none" />
<tr>
<td colspan="2" align="right" bgcolor="#eeeeee" style="border-bottom: 1px solid #cccccc"><strong>The Text</strong></td>
</tr>
<tr>
<td style="border-bottom: 1px dashed #cccccc">Enter what you want the glitter word to say</td>
<td style="border-bottom: 1px dashed #cccccc"><input type="text" name="text" class="bginput"/></td>
</tr>
<tr>
<td colspan="2" height="50" align="right"></td>
</tr>
<tr>
<td colspan="2" align="center"><input class="bginput" type="submit" value="Generate Glitter Text" /></td>
</tr>
</form>
</table>

</div>
</div>
<div id="footer"></div>
</div>

When you finally get to the end, it's not calling the echo.

The final result should be this. This is not using any templates, just straight on.
http://www.hellonturf.com/4image/glitter/glitter-word-code.php?type=hot-pink