Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2008-06-25 18:56:24

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

404 Error for sections that point to a custom template?

I’ve been pulling my hair out trying to pinpoint why any URL (http://mysite.com/section) that points to a custom template returns a 404 error. Sections that point to the default template work fine and my sections are set up correctly..

I’ve used textpattern with a few other sites and haven’t encountered this issue before.. Input would be appreciated!

Offline

#2 2008-06-25 20:02:24

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: 404 Error for sections that point to a custom template?

utamu wrote:

Sections that point to the default template work fine

Do the sections that return a 404 work if you temporarily assign the default template to them? If so, it must be something in the section template. Can you post your template’s code here?

Offline

#3 2008-06-26 06:10:13

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 8,595
Website GitHub Twitter

Re: 404 Error for sections that point to a custom template?

Also the section urls should read
http://mysite.com/section/
not
http://mysite.com/section
note the slash at the end.


Yiannis
——————————
neme.org | hblack.net | State Machines | NeMe @ github
I do my best editing after I click on the submit button.

Offline

#4 2008-06-30 17:55:36

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

Thanks for answering guys..

Honestly it seems like I get different results at any given time.. The site was working perfectly like a week ago… I dunno.But this what I’m seeing now:

If I point a section to either the default template or a custom template I can only spit out articles when using <txp:article /> with the default form. When I try to use a custom form I get the 404 error.

Here is my default template:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>

     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    <title>CocoAtl.com :: Chocolate, Gift Baskets, Gifts, Holidays </title>


	<link rel="home" href="<txp:site_url />" />


	<txp:feed_link flavor="atom" format="link" label="Atom" />

	<txp:feed_link flavor="rss" format="link" label="RSS" />


	<txp:css format="link" n="default" />

</head>



<body>



<div id="mwrapper">



	<div id="tmenu"> 

		<ul>

		<li><a href="#">home</a></li>

		<li><a href="#">about us</a></li>

        <li><a href="#">customer service</a></li>

		<li><a href="#">contact us</a></li>

		</ul>



		<txp:image class="logo" id="7" />
	</div>


<txp:image class="rotate" id="5" />


<div id="hbot">

   <div id="hlmenu"> 

   </div>


<txp:article  pgonly="0" status="4" />



</div>



<div id="footer">

        <h4> &copy; Copyright 2008 Chocolate Creations of Atlanta. </h4>

</div>



</div>


</body>


</html>

Offline

#5 2008-06-30 17:57:33

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

Here is my custom template:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>

     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    <title>CocoAtl.com :: Chocolate, Gift Baskets, Gifts, Holidays </title>

	<link rel="home" href="<txp:site_url />" />

	<txp:feed_link flavor="atom" format="link" label="Atom" />

	<txp:feed_link flavor="rss" format="link" label="RSS" />

	<txp:css format="link" />

      <script type="text/javascript" src="<txp:site_url />js/mootools.js"></script>

      <script type="text/javascript" src="<txp:site_url />js/slimbox.js"></script>

</head>


<body>


<div id="mwrapper">



	<div id="tmenu"> 

		<ul>

		<li><a href="#">home</a></li>

		<li><a href="#">about us</a></li>

        <li><a href="#">customer service</a></li>

		<li><a href="#">contact us</a></li>

		</ul>


		<txp:image class="logo" id="7" />

	</div>


<txp:image class="cat-img" id="4" />



<div id="ccont">

   <div id="clmenu"> 


   </div>

<txp:article />

</div>


<div id="footer">

        <h4> &copy; Copyright 2008 Chocolate Creations of Atlanta. </h4>



</div>




</div>





</body>

</html>

Offline

#6 2008-06-30 18:00:37

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

I was having a lot of trouble with my category links too (intended for shopping) but I removed them temporarily until I can figure out what the base issue is. That also was working fine a week ago sigh

And here is the form I would like to use for the custom template:

<div id= "prod-wrap">



   <div id="prod-listing">     

   <div id="prod-img-wrap">

   <txp:hak_article_thumb link="1" linktype="image" rel="lightbox" class="prod-thumb" />

   <h4>Click image to enlarge</h4>

   </div>



    <div id="prod-desc-wrap">

    <h2><txp:title /></h2>

    <txp:body />



    <strong><txp:custom_field name="Price" /></strong>



    <!-- Paypal Add to Cart Goes Here -->



     <form method="post" action="https://www.paypal.com/cgi-bin/webscr" target="paypal">

<input type="hidden" name="cmd" value="_cart">

<input type="hidden" name="business" value="email@gmail.com">

<input type="hidden" name="item_name" value="<txp:title />">

<input type="hidden" name="item_number" value="<txp:custom_field name="Item Number" />">

<input type="hidden" name="amount" value="<txp:custom_field name="Price" />">

<input type="hidden" name="currency_code" value="USD">

<input type="hidden" name="shipping" value="5.00">

<input type="hidden" name="shipping2" value="5.00">

<input type="hidden" name="handling_cart" value="5.00">

<input type="hidden" name="bn"  value="ButtonFactory.PayPal.001">

<input type="image" name="add" src="http://grandopusdesign.com/ajima/images/12.gif">

</form>


    </div>




   </div>



</div>

Offline

#7 2008-06-30 19:07:15

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: 404 Error for sections that point to a custom template?

utamu wrote:

If I point a section to either the default template or a custom template I can only spit out articles when using <txp:article /> with the default form. When I try to use a custom form I get the 404 error.

Just to make sure I understand you correctly, are you saying that whenever you change <txp:article /> to <txp:article form="the-form-that-you-posted-above" /> you get a 404?

Offline

#8 2008-06-30 19:13:00

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

Els wrote:

utamu wrote:

If I point a section to either the default template or a custom template I can only spit out articles when using <txp:article /> with the default form. When I try to use a custom form I get the 404 error.

Just to make sure I understand you correctly, are you saying that whenever you change <txp:article /> to <txp:article form="the-form-that-you-posted-above" /> you get a 404?

Yup..

Last edited by utamu (2008-06-30 19:14:09)

Offline

#9 2008-06-30 19:24:03

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: 404 Error for sections that point to a custom template?

From TextBook:

Custom [field] names may include letters (uppercase or lowercase), numbers and under_scores, but no spaces or other special characters.

Try to change the name of your custom field ‘Item Number’.

Last edited by els (2008-06-30 19:25:24)

Offline

#10 2008-06-30 19:35:47

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

Els wrote:

From TextBook:

Custom [field] names may include letters (uppercase or lowercase), numbers and under_scores, but no spaces or other special characters.

Try to change the name of your custom field ‘Item Number’.

I changed the custom field name but I still got the 404..

Offline

#11 2008-06-30 19:55:02

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: 404 Error for sections that point to a custom template?

Are clean URLs working? what does the Admin -> Diagnostics tab say?


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#12 2008-06-30 20:03:54

utamu
Member
From: upstate NY, USA
Registered: 2006-12-05
Posts: 20

Re: 404 Error for sections that point to a custom template?

maniqui wrote:

Are clean URLs working? what does the Admin -> Diagnostics tab say?

I think so..

Here’s the Diagnostics:

Textpattern version: 4.0.6 (r2805)
Last Update: 2008-06-25 15:02:26/2008-06-25 14:58:22
Document root: /home/utamu/public_html
$path_to_site: /home/utamu/public_html/ajima
Textpattern path: /home/utamu/public_html/ajima/textpattern
Permanent link mode: section_title
Temporary directory path: /home/utamu/public_html/ajima/textpattern/tmp
Site URL: grandopusdesign.com/ajima
PHP version: 5.2.2
GD Image Library: version bundled (2.0.34 compatible), supported formats: GIF, JPG, PNG
Server Local Time: 2008-06-30 15:02:25
MySQL: 4.1.22-standard
Locale: en_US.UTF-8
Server: Apache/1.3.39 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.30 OpenSSL/0.9.7a PHP-CGI/0.1b
PHP Server API: cgi
RFC 2616 headers: 0
Server OS: Linux 2.6.24.3-grsec
Active plugins: hak_tinymce-0.7.4, hak_article_image-0.6.3, fpx_image_import-0.4, rss_unlimited_categories-0.7.4

Pre-flight check:
————————————
/home/utamu/public_html/ajima/textpattern/setup/ still exists
————————————

.htaccess file contents:
————————————
#DirectoryIndex index.php index.html

#Options +FollowSymLinks
#Options -Indexes

<IfModule mod_rewrite.c> RewriteEngine On #RewriteBase /relative/web/path/

RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^(.+) – [PT,L]

RewriteRule ^(.*) index.php

RewriteCond %{HTTP:Authorization} !^$ RewriteRule .* – [E=REMOTE_USER:%{HTTP:Authorization}]
</IfModule>

#php_value register_globals 0

————————————

Charset (default/config): latin1/utf8
character_set_client: utf8
character_set_connection: utf8
character_set_database: latin1
character_set_results: utf8
character_set_server: latin1
character_set_system: utf8
character_sets_dir: /usr/share/mysql/charsets/
18 Tables: txp_hak_tinymce is latin1

PHP extensions: xmlwriter/0.1, libxml, xmlrpc/0.51, dom/20031129, xmlreader/0.1, xml, wddx, tokenizer/0.1, session, pcre, SimpleXML, SPL, PDO, sockets, soap, SQLite, standard/5.2.2, Reflection, posix, pdo_sqlite/1.0.1, pdo_mysql/1.0.2, mysqli/0.1, mysql/1.0, mhash, mcrypt, mbstring, json/1.2.1, imap, iconv, hash/1.0, gettext, gd, ftp, filter/0.11.0, exif/1.4 $Id: exif.c,v 1.173.2.5.2.19 2007/02/27 03:04:40 iliaa Exp $, date/5.2.2, curl, ctype, calendar, bcmath, zlib/1.1, openssl, cgi, ionCube Loader, Zend Optimizer

pretext_data: array ( ‘id’ => ‘’, ‘s’ => ‘’, ‘c’ => ‘’, ‘q’ => ‘’, ‘pg’ => ‘’, ‘p’ => ‘’, ‘month’ => ‘’, ‘author’ => ‘’, ‘request_uri’ => ‘/ajima/32107f9932ca2fd3da1dbf1d6e4f4590/?txpcleantest=1’, ‘qs’ => ‘txpcleantest=1’, ‘subpath’ => ‘\\/ajima\\/’, ‘req’ => ‘/32107f9932ca2fd3da1dbf1d6e4f4590/?txpcleantest=1’,
)

/../index.php: r2774 (66519e6f500fa0e59fa27567e97d3675)
/css.php: r2772 (4807cbc15661213f2b4d0fd26c7179ff)
/include/txp_admin.php: r2729 (0c2b3cf59ff433c943bcc293a526651a)
/include/txp_article.php: r2680 (49a7155d831f843bcf3e8de306dfe7f1)
/include/txp_auth.php: r2728 (c472bfbe49a71fd35e89000c8a18de08)
/include/txp_category.php: r2243 (0ed99b6f44b5d221bdf35674240141ab)
/include/txp_css.php: r2730 (7974aa87728b39d3afaba5a3b18cf6b5)
/include/txp_diag.php: r2791 (aeb96445180b68c31821e237b6150332)
/include/txp_discuss.php: r2774 (852a8a4d4307358e161e0501124b7247)
/include/txp_file.php: r2530 (9f34fdbf98b9b649d65e2ced4c9ca763)
/include/txp_form.php: r1913 (780340d28f384113c72924843194b43e)
/include/txp_image.php: r2668 (11269b464db6cfa3affff47674533a50)
/include/txp_import.php: r1238 (86f0e64d2c9362066e6c48b9cd486e37)
/include/txp_link.php: r2463 (2379d25f83b37ec6c8d5f3edb1122ce8)
/include/txp_list.php: r2725 (1ed6c6f729eaeb7f8a582b27cd5b9e78)
/include/txp_log.php: r2796 (f249e0962a996f05041b899fea91ccae)
/include/txp_page.php: r2717 (807ff04b4a649b54b3d710c1ab0a428f)
/include/txp_plugin.php: r2774 (e9fdc47a3ed9bdd13197d929161c6a13)
/include/txp_prefs.php: r2528 (50bd3be8c22e17d5ca2855ccea081bac)
/include/txp_preview.php: r1238 (c45992b3273ac8019477e2f959d63120)
/include/txp_section.php: r2759 (9208297e0bd7b3d41bd0e6f9fc9ab120)
/include/txp_tag.php: r2774 (f371b400e8d7318e2ac48e032fe6c274)
/index.php: r2805 (ee8ab2e3c4bc9abd77aa7384ecba5268)
/lib/IXRClass.php: r765 (0120eb4713c9b6446a0eebe8b1039d1c)
/lib/admin_config.php: r1747 (b972529744cb37a7695fe00316dada41)
/lib/class.thumb.php: r2329 (c7f66a32531f32d6dfcbe5c7d26c7852)
/lib/classTextile.php: r2779 (b6d5b9cecbc5bc6475b5d1ee6a5231ea)
/lib/constants.php: r2361 (5338211ece1b2592804acdd204c9df33)
/lib/taglib.php: r2612 (727737ebd08127c632b9822bae87fee0)
/lib/txplib_admin.php: r2726 (c4f65bac2ddef62867f5bfee97ad7dfe)
/lib/txplib_db.php: r2748 (3feb369b1c34f251815cd6085a216d62)
/lib/txplib_forms.php: r2759 (a2d3de62110e582fab2a3a20224661f4)
/lib/txplib_head.php: r2783 (74ced647523a94da307af9853d7ed596)
/lib/txplib_html.php: r2696 (57985ebd2501bc303d2e97ae7538db1f)
/lib/txplib_misc.php: r2788 (7ecfaa5d4fabefbf411d01615dea9485)
/lib/txplib_update.php: r1239 (e3bd2d0c2b491d4028a656b8301a0086)
/lib/txplib_wrapper.php: r2800 (4ad38ee67f3ee8d9e7b51544a4f0f58b)
/publish.php: r2777 (0ce3da212329e7d34de07e53e109d182)
/publish/atom.php: r2774 (50aa384a2edf7cc07effee9020e0893b)
/publish/comment.php: r2776 (0e1ea64316087edcd75f394494b42100)
/publish/log.php: r1637 (f69237dc2ff39bd7a691c8ca1bc87808)
/publish/rss.php: r2793 (022caa22c756c64f2255aae6625686d8)
/publish/search.php: r1748 (ea84e04b2c688b0bb8b5a9ecf395749a)
/publish/taghandlers.php: r2774 (59dc36e6dabc619e23c43f722fe7b8f1)
/update/_to_1.0.0.php: r711 (0f49fca8fbd8e6fca0fc48b0f69f0461)
/update/_to_4.0.2.php: r711 (e77c0e0d972868f19eaee4565bd0b4c4)
/update/_to_4.0.3.php: r711 (f5506cfd0fbc3ad4bd9a9b2299468775)
/update/_to_4.0.4.php: r711 (4d867b42ee87a7f11d2bff3a8e91bed0)
/update/_to_4.0.5.php: r2464 (dbe80cd4a775d3a43a203c3c4a2d0e3f)
/update/_to_4.0.6.php: r2464 (7e5ae73eb64c24438918697089a1f321)
/update/_update.php: r2792 (6ff7b4dedb2c7735a01e76b13b3f1fb1)

Offline

Board footer

Powered by FluxBB