Zen Cart Logo
Forums / Customization from the Admin / Cant edit my define_main_page.php ?!

Cant edit my define_main_page.php ?!

Views: 1,888

Results 1 to 16 of 16
26 Dec 2012, 4:49 PM
#1
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Cant edit my define_main_page.php ?!

Hi, I can not change my define_main_page.php. I purchased a template and now I can not change the main text, there may be no way to turn on and off via admin panel? I even tried changing the files manualy but did not succeed. On the buy side when they showed screenshot, it seems that they have been able to change the text, I do not understand what is the problem? It works when I change the zen carts base template.

Have them may have removed the display codes?!
My site: http://butik.topfeste.com

26 Dec 2012, 6:21 PM
#2
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Location:
UK
Posts:
1,780
Plugin Contributions:
2

Re: Cant edit my define_main_page.php ?!

What are your read/write permissions on your template defines fines? Is it that you cannot save your changes or that the files don't appear as part of your template?

26 Dec 2012, 7:31 PM
#3
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

I changed permissions 777 on ALL files! Still dosent work :S

26 Dec 2012, 7:41 PM
#4
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Location:
UK
Posts:
1,780
Plugin Contributions:
2

Re: Cant edit my define_main_page.php ?!

Topfeste:

I changed permissions 777 on ALL files! Still dosent work :S

Where did you purchase your template? Perhaps post a link to it.

26 Dec 2012, 8:10 PM
#6
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Location:
UK
Posts:
1,780
Plugin Contributions:
2

Re: Cant edit my define_main_page.php ?!

where on the page is the text you are trying to edit?

26 Dec 2012, 8:16 PM
#7
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

Middle of the page The collection banners, im trying to put them in the main! Like on - http://template-demo.net/zen/ZEN01/ZEN010016/ <-

<td valign="top"> <div class="MainBanner"> <div id="bannerOne" class="banners"><img src="../images/mainbanner.jpg" alt="MainBanner" title=" MainBanner " width="757" height="324" /></div> </div><div class="MainBottomBanner"><div id="bannerTwo" class="banners"><img src="../images/banner1.jpg" alt="MainBottom1" title=" MainBottom1 " width="373" height="185" /></div><div id="bannerThree" class="banners"><img src="../images/banner2.jpg" alt="MainBottom3" title=" MainBottom3 " width="374" height="185" /></div> </div>

If i could get any text at least.

26 Dec 2012, 8:54 PM
#8
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Location:
UK
Posts:
1,780
Plugin Contributions:
2

Re: Cant edit my define_main_page.php ?!

if I read you correctly then you need to be looking at banner manager in your admin>tools. The part you are trying to edit is an image.

26 Dec 2012, 9:08 PM
#9
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

Hm okey but why cant i edit text in define_main_page.php? When i do that nothing displays at main site? When i do it on zen cart default template it displays :S

26 Dec 2012, 10:25 PM
#10
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Location:
UK
Posts:
1,780
Plugin Contributions:
2

Re: Cant edit my define_main_page.php ?!

Topfeste:

Hm okey but why cant i edit text in define_main_page.php? When i do that nothing displays at main site? When i do it on zen cart default template it displays :S

how are you trying to input your text, via define page editor in admin>tools or by editing the file via ftp?

26 Dec 2012, 11:51 PM
#11
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

i tried both of them, via define page and manualy by editing the file via ftp. still dosent work :S

the text i write via admin panel at define main page saves in the box field but it dosent shows on main page, dont understand why? it works on the default theme:S

27 Dec 2012, 12:48 AM
#12
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Cant edit my define_main_page.php ?!

The banner areas are not output by define_main_page.php, so editing that will do nothing to the banners. The define page content should appear between these tags, so is not being output in the demo.

<div id="indexDefaultMainContent" class="content">
	</div>

What do you have in /includes/templates/your_template/templates/tpl_index_default.php around those tags? Post it here in code tags.

27 Dec 2012, 12:54 AM
#13
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

<?php /** * Page Template * * Main index page<br /> * Displays greetings, welcome text (define-page content), and various centerboxes depending on switch settings in Admin<br /> * Centerboxes are called as necessary * * @package templateSystem * @copyright Copyright 2003-2006 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * @version $Id: tpl_index_default.php 3464 2006-04-19 00:07:26Z ajeh $ */ ?> <div class="centerColumn" id="indexDefault"> <!-- deprecated - to use uncomment this section <?php if (TEXT_MAIN) { ?> <div id="" class="content"><?php echo TEXT_MAIN; ?></div> <?php } ?>--> <!-- deprecated - to use uncomment this section <?php if (TEXT_INFORMATION) { ?> <div id="" class="content"><?php echo TEXT_INFORMATION; ?></div> <?php } ?>--> <?php if (DEFINE_MAIN_PAGE_STATUS >= 1 and DEFINE_MAIN_PAGE_STATUS <= 2) { ?> <?php /** * get the Define Main Page Text */ ?> <div id="indexDefaultMainContent" class="content"> <?php // require($define_page); ?> </div> <?php } ?> <?php $show_display_category = $db->Execute(SQL_SHOW_PRODUCT_INFO_MAIN); while (!$show_display_category->EOF) { ?> <?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_FEATURED_PRODUCTS') { ?> <?php /** * display the Featured Products Center Box */ ?> <?php require($template->get_template_dir('tpl_modules_featured_products.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_featured_products.php'); ?> <?php } ?> <?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_SPECIALS_PRODUCTS') { ?> <?php /** * display the Special Products Center Box */ ?> <?php require($template->get_template_dir('tpl_modules_specials_default.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_specials_default.php'); ?> <?php } ?> <?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_NEW_PRODUCTS') { ?> <?php /** * display the New Products Center Box */ ?> <?php require($template->get_template_dir('tpl_modules_whats_new.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_whats_new.php'); ?> <?php } ?> <?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_UPCOMING') { ?> <?php /** * display the Upcoming Products Center Box */ ?> <?php include(DIR_WS_MODULES . zen_get_module_directory(FILENAME_UPCOMING_PRODUCTS)); ?><?php } ?> <?php $show_display_category->MoveNext(); } // !EOF ?> </div>
27 Dec 2012, 1:03 AM
#14
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

gjh42:

The banner areas are not output by define_main_page.php, so editing that will do nothing to the banners. The define page content should appear between these tags, so is not being output in the demo.

<div id="indexDefaultMainContent" class="content"> </div> ``` > What do you have in /includes/templates/your_template/templates/tpl_index_default.php around those tags? Post it here in code tags.

If i try " <div id="indexDefaultMainContent" class="content">Test</div> " just so i will se of i get any text at all. Dosent get any text at all on define main page :(

27 Dec 2012, 1:13 AM
#15
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Cant edit my define_main_page.php ?!

<div id="indexDefaultMainContent" class="content">
<?php // require($define_page); ?>
</div>
```The // comments out the require, so define_main_page.php has been forcibly disabled by your template designer (a typical Template Monster behavior). Just remove the // and it will work as it should.
27 Dec 2012, 11:30 AM
#16
topfeste avatar

topfeste

New Zenner

Join Date:
Dec 2012
Posts:
9
Plugin Contributions:
0

Re: Cant edit my define_main_page.php ?!

oh lol :S haha! its work! thanks alot.