Jump to content

 

zanimo

Member Since 04 Feb 2008
Offline Last Active Jan 24 2009 02:44 PM
-----

Posts I've Made

In Topic: Import Newsletter subscribers

26 March 2008 - 09:17 PM

I have the same problem

I am not familiar with SQL commands, what do I do to get

In Topic: RSS script, only Product Title and Description

10 March 2008 - 06:38 AM

zanimo check your database username and password


oups... thanks it's ok now.

In Topic: RSS script, only Product Title and Description

09 March 2008 - 09:36 PM

Hi guys, i was messing around with some php scripts that will create an RSS feed of your Product title and Description.

First create a PHP file "rss.php" add the following code into it and put it in your root dir (or create an rss directory and put it there). The CDATA commands helps the parsing of some characters in xml format so the feed gets validated and show up correctly.

<? header('Content-type: text/xml'); ?>


<?php

$dbhost = "localhost"; // almost always localhost.

$dbname = "databasename"; // Database Name, In our case, its news

$dbuser = "username"; // Database Username

$dbpass = "password"; // Databse Password



$connect = mysql_connect("$dbhost","$dbuser","$dbpass");// Connecting to Database

mysql_select_db($dbname) or die (mysql_error()); // Selecting Database

?>

<rss version="2.0">

<channel>


<title>Your Title Here</title>
<link>Link of you page</link>
<description>Description of your store</description>

<?

$sql = "SELECT * FROM cscart_product_descriptions";

$result = mysql_query($sql);

while($row = mysql_fetch_assoc($result)){

?>
<item>
<title><?=$row['product']; ?></title>
<description><![CDATA[<?=$row['full_description']; ?>]]></description>
<link>http://www.yoursite.com/index.php?target=products<![CDATA[&]]>product_id<![CDATA[=]]><?=$row['product_id']; ?></link>
</item>
<?
}
?>
</channel>
</rss>


Of course you can play with the rows and add short description instead of full. I was trying to grab data from the "cscart_products" table to list the price from the "list_price" row but i dont know how to do it. My knowledge is very limited, if someone else could make this happen it would be great!

If you like, for security reasons you can make an additional 'config.php' file to open the connection to the database and store it in a safer place than the root of your server and then insert an "include" command inside the 'rss.php' to call it.

Here in Greece RSS feeds for online stores are usefull in some ways especially in sites like the froogle but in Greek version but it's not free ;)

Feel free to make any suggestion to a n00b! :D


Hello i have this error

<b>Warning</b>: mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Acce...

Thanks.

In Topic: Listmania - Newest products in subcategories?

25 February 2008 - 08:34 PM

Hello,

Normally you can see what's new in the sub-categories as well.

However, I ask the following question: is it possible to display in the new correponsdant to the category?

Ex: category dog, cat, fish.

Show only new items (dog) in the category dog ...

Sorry for my english

In Topic: Change the size of the price box ?

24 February 2008 - 10:11 PM

You need to change the width in style.css and style_ie.css the class product-details-options.


thanks you very much.

It's good now.