Support Forums

seller list

This is a discussion on seller list within the Modules / Plugins / Modifications forums, part of the Developer Forums category; Originally Posted by bowers01 Create a php page, in this case dealers.php PHP Code: <?php require_once( 'includes/init.php' ); require_once( FILESYSTEM_PATH  ...


Go Back   68 Classifieds Forums > Developer Forums > Modules / Plugins / Modifications

Reply
 
Thread Tools Display Modes
Old 08-22-2010, 10:30 AM   #11
Customer
 
Join Date: Mar 2010
Posts: 5
Rep Power: 0
ehabkhriees is on a distinguished road
Unhappy

Quote:
Originally Posted by bowers01
Create a php page, in this case dealers.php
PHP Code:
<?php
require_once('includes/init.php');
require_once(
FILESYSTEM_PATH .'modules/seller_store/includes/functions.php');
require_once(
FILESYSTEM_PATH .'includes/classes/kernel/Users.php');


        
$sSQL "SELECT s.sID,s.sUserID,s.sTitle,s.sDescription,s.sImage,u.city,u.state,u.phone FROM ".PREFIX."store AS s LEFT JOIN ".PREFIX."users AS u ON s.sUserID = u.id";
        
$result=$db->query($sSQL);
        
$data=array();
        while(
$rs $result->fetch())
        {
            
$data[]=$rs;
        }
        
$class_tpl->assign('results'$data);
        
$class_tpl->assign('body','dealers.tpl');
        
$class_tpl->display('layout.tpl');

?>
then a template file call dealers witht he following
Code:
<fieldset>
	<legend>Current Dealers</legend>
				<table width="100%"  border="0" cellspacing="0" cellpadding="3">
				<tr>
					<td align="center"><h3>Dealer Name</h3></td>
					<td align="center"><h3>Phone</h3></td>
					<td align="center"><h3>View Items</h3></td>
					<td align="center"><h3>Logo</h3></td>
				</tr>
				{foreach from=$results item="entry"}
				<tr>
		          	<td class="{cycle values="row1,row2" advance=false}" align="center"><a href="{$smarty.const.URL}/searchresults.php?owner={$entry.sUserID}"><br /><strong>{$entry.sTitle|replace:'&':'&'}</strong><br />{$entry.city}, {$entry.state}</a><br /><br /></td>
					<td class="{cycle values="row1,row2" advance=false}" align="center">{$entry.phone}</td>
					<td class="{cycle values="row1,row2" advance=false}" align="center"><a href="{$smarty.const.URL}/searchresults.php?owner={$entry.sUserID}">View Items</a></td>
					<td class="{cycle values="row1,row2" advance=true}" align="center"><a href="{$smarty.const.URL}/searchresults.php?owner={$entry.sUserID}">{if $entry.sImage == ""}{$entry.sTitle|replace:'&':'&'}{else}<img src="http://photos.truckandmachinery.com.au/{$entry.sImage}" width="400px" alt="{$entry.sTitle}" />{/if}</a></td>
				</tr>
				{foreachelse}
					<tr><td colspan="5">{$smarty.const.LANG_NO_RESULTS}</td></tr>
				{/foreach}
				</table>
</fieldset>

hi nick when i tried your code i got the following error message , i try to resolve it but no use

Warning: Smarty error: unable to read resource: "dealers.tpl" in /home2/metalyar/public_html/includes/classes/smarty/Smarty.class.php on line 1092

is it becuase of http://photos.truckandmachinery.com.au/{$entry.sImage} in your second code.

can you please help
ehabkhriees is offline   Reply With Quote
Old 08-22-2010, 06:35 PM   #12
Genius At Work
 
bowers01's Avatar
 
Join Date: May 2008
Location: Geelong, Victoria, Australia
Posts: 1,089
Rep Power: 35
bowers01 is on a distinguished road
Default

Hi,
It appears you have not got a dealers.tpl file in the template directory.
If you copy the second lot of code into the dealer.tpl file it should work.
You will also need to change the image path from
http://photos.truckandmachinery.com.au/{$entry.sImage}
to
{$smarty.const.URL}/photos/{$entry.sImage}

Regards,
Nick
__________________
Nick Bowers
68c v4.1.10 Developer Custom Template
bowers01 is offline   Reply With Quote
Old 08-25-2010, 02:32 PM   #13
Customer
 
Join Date: Mar 2010
Posts: 5
Rep Power: 0
ehabkhriees is on a distinguished road
Default place an ads is not working when i select other language

hi ,
can someone help with problem I�m facing when I select language other than English , as user I couldn�t complete my order it�s just freeze on the stage 2 and address field it show following without parameter :
http://www.domainname.com/usercheckout.php
but if i will select English , then I can proceed with the order
ehabkhriees is offline   Reply With Quote
Old 08-25-2010, 02:44 PM   #14
curmudgeon
 
Join Date: Mar 2006
Posts: 5,413
Rep Power: 138
Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light
Default

Quote:
Originally Posted by ehabkhriees
hi ,
can someone help with problem I�m facing when I select language other than English , as user I couldn�t complete my order it�s just freeze on the stage 2 and address field it show following without parameter :
but if i will select English , then I can proceed with the order
Have no idea what your post has to do with this thread but 68C default behaqvior doesnt allow the user to select a different language that I am aware of. So it soulds like our using a mod or have hacked the code yourself. If the former, talk to the company you got the mod from, if the latter, no one here will be able to help.
__________________
Larry

Knowledge learned is more valuable than knowledge given.
Lhotch is offline   Reply With Quote
Old 12-30-2010, 07:07 AM   #15
Customer
 
Join Date: Dec 2008
Posts: 2
Rep Power: 0
zuherkanji is on a distinguished road
Default question for the post

thanks for this post

i have a question, how do you add the option

User Type: Private Advertiser Dealer
zuherkanji is offline   Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Generate List of Seller Stores bowers01 Modules / Plugins / Modifications 4 12-21-2008 12:56 PM
Private seller AND Commercial Seller !!! Respectful user Pre Sales Questions 5 09-05-2008 11:06 PM


All times are GMT -4. The time now is 07:00 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2011, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0