Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Creating table - I don't know how


Lao

Recommended Posts

I'm trying to make Custom Computer Configurator work within my site. I made all the changes to the required files and now I'm stuck with creating tables in database. I really don't know how.

 

I have to put these in a new table. How do I do that?

 

CREATE TABLE `ccc_cat` (
 `cat_id` int(11) NOT NULL auto_increment,
 `status` tinyint(2) NOT NULL default '1',
 `cat_req` tinyint(2) NOT NULL default '0',
 `sort_order` int(11) NOT NULL default '0',
 `sys_id` int(11) NOT NULL default '0',
 `fsb_id` int(11) NOT NULL default '0',
 KEY `cat_id` (`cat_id`)
) TYPE=MyISAM AUTO_INCREMENT=5;

#
# Dumping data for table `ccc_cat`
#

INSERT INTO `ccc_cat` VALUES (4, 1, 0, 1, 5, 5);
INSERT INTO `ccc_cat` VALUES (4, 1, 0, 1, 5, 6);

 

 

I went to my databes and made the "ccc_cat" table with "Create new table in database", I added the first fields and now I don't know what to do, I'm stuck at this point:

 

image27gv.th.jpg

 

Is this ok? What do I do next? Please help!

Sorry for my bad english language!

Link to comment
Share on other sites

Here's a movie about how I did the teables. Please take a look at it and tell me what I did wrong, my site is still not working. :((

 

MY CLIP

Sorry for my bad english language!

Link to comment
Share on other sites

Anyone?! I'm still not able to do this right and I really need that CCC.

 

I get this error and I think it's something in header.php also:

 

image36wa.th.jpg

Sorry for my bad english language!

Link to comment
Share on other sites

Anyone?! I'm still not able to do this right and I really need that CCC.

 

I get this error and I think it's something in header.php also:

 

image36wa.th.jpg

 

for the error mesaage "unable to determine page link" turn off "enable search engine freindly urls" in admin - configuration

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

All you needed to do was access PHPMyAdmin, select your database, select the SQL tab, and paste all of the code you pasted in your original post into the textbox, and click ok.

 

Technically, everything should have been in an .sql file that you could have selected to upload at the bottom of the page I mentioned above.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

@crash3903: It was turned off already. I turned it on and I have the same error. :(

 

@Daemonj: So I did it ok the way I did it, but with some extra work. Right? Anyway, I did it again the way you said, just to be sure I didn't miss any thing.

 

 

Thanks for replying guys, but what can I do to get it right? It still doesn't work.

Sorry for my bad english language!

Link to comment
Share on other sites

Are you getting an error message or *what* isn't working?

 

In your original post, you just said that you needed to create the tables, which you have now done.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

You're right, sorry! I wasn't clear on that one.

 

I'm still getting that error in header.

 

I thought it was from my modified header and I replaced it with an original header.php file from oscommerce kit. I then added the code bellow in this header.php , but I'm still getting the error I showed to you in my second post. This is the code I have to add to my header.php:

 

Around Line 55 Add:

//CCC DEFINES
define('HEADER_TITLE_CUSTOM_BUILD', 'Custom Computer Creator');
if (tep_session_is_registered('ccc_prod_id')){
$edit_params = 'edit=1';
$link_file = FILENAME_CCC_BUILD;
}else{
$link_file = FILENAME_CCC;
$edit_params = '';
}
//END

 

 

The other modifications I have to make to header.php are:

 

Around Line 72 Replace

<table border="0" width="100%" cellspacing="0" cellpadding="1">
 <tr class="headerNavigation">
<td class="headerNavigation">  <?php echo $breadcrumb->trail(' ? '); ?></td>
<td align="right" class="headerNavigation"><?php if (tep_session_is_registered('customer_id')) { echo '<a href="' . tep_href_link(FILENAME_LOGOFF, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_LOGOFF . '</a>  |  '; } echo '<a href="' . tep_href_link(FILENAME_ACCOUNT, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_MY_ACCOUNT . '</a>  |  <a href="' . tep_href_link(FILENAME_SHOPPING_CART) . '" class="headerNavigation">' . HEADER_TITLE_CART_CONTENTS . '</a>  |  <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_CHECKOUT . '</a>'; ?>  </td>
 </tr>
</table>

 

WITH:

<table border="0" width="100%" cellspacing="0" cellpadding="1">
 <tr class="headerNavigation">
<td class="headerNavigation">  <?php echo $breadcrumb->trail(' ? '); ?></td>
<td align="right" class="headerNavigation"><?php if (tep_session_is_registered('customer_id')) { echo '<a href="' . tep_href_link(FILENAME_LOGOFF, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_LOGOFF . '</a>  |  '; } echo '<a href="' . tep_href_link($link_file, $edit_params, 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_CUSTOM_BUILD . '</a>  |  <a href="' . tep_href_link(FILENAME_ACCOUNT, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_MY_ACCOUNT . '</a>  |  <a href="' . tep_href_link(FILENAME_SHOPPING_CART) . '" class="headerNavigation">' . HEADER_TITLE_CART_CONTENTS . '</a>  |  <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '" class="headerNavigation">' . HEADER_TITLE_CHECKOUT . '</a>'; ?>  </td>
 </tr>
</table>

 

 

I did all that I don't understand what's wrong with it.

Sorry for my bad english language!

Link to comment
Share on other sites

You're right, sorry! I wasn't clear on that one.

 

I'm still getting that error in header.

 

I thought it was from my modified header and I replaced it with an original header.php file from oscommerce kit. I then added the code bellow in this header.php , but I'm still getting the error I showed to you in my second post. This is the code I have to add to my header.php:

 

Around Line 55 Add:

//CCC DEFINES
define('HEADER_TITLE_CUSTOM_BUILD', 'Custom Computer Creator');
if (tep_session_is_registered('ccc_prod_id')){
$edit_params = 'edit=1';
$link_file = FILENAME_CCC_BUILD;
}else{
$link_file = FILENAME_CCC;
$edit_params = '';
}
//END

 

 

That code needs to be placed within PHP blocks. Based upon your screen shot, it was placed outside of a PHP block and instead placed within an HTML block.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

Am I n00b or what? :D

 

Thanks for all the help you gave me, but now I have a new (personal) problem: I don't like this CCC or I don't know exactly how to use it in Admin. Did you use it or do you know someone on the forums tha used it and is happy with it? :(

Sorry for my bad english language!

Link to comment
Share on other sites

I have not used it nor know anyone that has.

 

You could do a search of the Contributions section for the CCC support thread or you could start a thread in the General Support forum seeking that information and suggestions.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

I found a thread in Contributions Support where someone says that CCC 9.3 is a little buggy and has no support, so I swiched to PC Pro Creator contrib. I have some little problems with this one too, but it looks a little more easy to use and integrate in my site. ;)

Sorry for my bad english language!

Link to comment
Share on other sites

Good luck and I hope it goes well for you. :)

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...