Hey everybody..
Firstly... I love Gallery and Phpnuke....but im having a problem..ive intergrated a simple shopping cart into view_photo.php in the gallery. It works fine using the gallery as a standalone...but when i intergrate it into phpnuke, when i order something it does not add it to the shopping cart or show the popup window saying that the item has been added... i have no idea why either....and because im new at php and i didnt write the code for the shopping cart i dont know how to fix it... Here is the code thats was added to the view_photo.php
echo("</td>");
echo("<td $bordercolor width=$borderwidth>");
echo("<img src=$top/images/pixel_trans.gif width=$borderwidth height=1>");
echo("</td>");
echo("</tr>");
echo("<tr $bordercolor>");
echo("<td colspan=3 height=$borderwidth><img src=$top/images/pixel_trans.gif></td>");
?>
</tr>
</table>
//CODE STARTS HERE
Order Prints:<br>
<form name="order" action="modules/Gallery/cart/managecart.html">
<input type=text size=2 maxlength=3 name=QUANTITY onChange='this.value=CKquantity(this.value)' value="1">
<input type=hidden name=PRICE value="12.50">
<input type=hidden name=NAME value="4x6">
<input type=hidden name=ID_NUM value="<?php echo $photoURL;?>">
<input type=hidden name=SHIPPING value="0">
<input type="submit" value="4x6" onClick='AddToCart(this.form)'>$12.50
</form>
<form name="order" action="modules/Gallery/cart/managecart.html">
<form name="order" action="modules/Gallery/cart/managecart.html">
<input type=text size=2 maxlength=3 name=QUANTITY onChange='this.value=CKquantity(this.value)' value="1">
<input type=hidden name=PRICE value="17.50">
<input type=hidden name=NAME value="5x7">
<input type=hidden name=ID_NUM value="<?php echo $photoURL;?>">
<input type=hidden name=SHIPPING value="0">
<input type="submit" value="5x7" onClick='AddToCart(this.form)'>$17.50
</form>
<form name="order" action="modules/Gallery/cart/managecart.html">
<input type=text size=2 maxlength=3 name=QUANTITY onChange='this.value=CKquantity(this.value)' value="1">
<input type=hidden name=PRICE value="35.00">
<input type=hidden name=NAME value="8x10">
<input type=hidden name=ID_NUM value="<?php echo $photoURL;?>">
<input type=hidden name=SHIPPING value="0">
<input type="submit" value="8x10" onClick='AddToCart(this.form)'>$35.00
</form>
<form name="order" action="modules/Gallery/cart/managecart.html">
<input type=text size=2 maxlength=3 name=QUANTITY onChange='this.value=CKquantity(this.value)' value="1">
<input type=hidden name=PRICE value="70.00">
<input type=hidden name=NAME value="11x14">
<input type=hidden name=ID_NUM value="<?php echo $photoURL;?>">
<input type=hidden name=SHIPPING value="0">
<input type="submit" value="11x14" onClick='AddToCart(this.form)'>$70.00
</form>
<a href="modules/Gallery/cart/managecart.html">View Cart</a>
<table border=0 width=<?=$mainWidth?> cellpadding=0 cellspacing=0>
//CODE ENDS HERE
<!-- caption -->
<tr>
<td colspan=3 align=center>
<span class="caption"><?= editCaption($gallery->album, $index, $edit) ?></span>
<br><br>
</td>
</tr>
<? if (!strcmp($gallery->album->fields["public_comments"], "yes")) { ?>
<tr>
<td colspan=3 align=center>
<!-- comments -->
<span class="caption"><?= viewComments($index) ?></span>
<br><br>
</td>
</tr>
<? } ?>
<?
if (!strcmp($gallery->album->fields["print_photos"],"none") ||
$gallery->album->isMovie($id)) {
I dunno if that will help ya but Could someone please help me i am willing to pay money.....my site that the shopping cart is on is http://www.rocksea.com.au and the gallery is in the view photos online section. If you need the files that the shopping cart requires just email me.
Kind Regards
MiST
Posts: 8
Not sure how this works with PHPnuke but here is how I did a shopping cart with paypal.
http://gallery.menalto.com/modules.php?op=modload&name=phpBB_14&file=index&action=viewtopic&topic=1098&4749