14 Jan 2009, 11:33
Generic-user-small

chh (1 post)

I am having trouble getting the title_permalink to redirect correctly. On my sandbox environment, clicking the “read more” link redirects the user to a blank page (like the screencast). However, when I cut and paste the same code into my live site, the link redirects the user to the correct address, but the page content looks exactly like my site/index.php page (the page with the “read more” link). Both environments were created in parallel, and are virtually the same.

<div id="PrimaryArticle">
  {exp:weblog:entries weblog="news_articles" limit="1" status="Primary Article"}
  <h4>{title}</h4>
  <h5>by {author}</h5>
  {news_article_excerpt}
  <p><a href="{title_permalink="news_articles/view"}">Read more</a></p>
  {/exp:weblog:entries}
</div>

Any ideas?

19 Feb 2009, 01:15
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

I’m having the same issue…

19 Feb 2009, 01:36
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

and also, when I’m in the control panel and I’m editing the “view” template, when I click on “view rendered template” the page content looks exactly like my site/index.php page (the page with the “read more” link)….

19 Feb 2009, 14:59
Ryanirelan_headshot_48x48_pragsmall

Ryan Irelan (218 posts)

Adele, what is the URL that EE creates using that code?

20 Feb 2009, 05:17
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

Hi Ryan – the “view rendered template” url is http://wilsonhamaker.com/ee/index.php/news_articles/view/

When I’m on the site index page (the one with the “top stories”, etc) and I click on the “read more” link to follow the story to it’s own page, this is the url I get: http://wilsonhamaker.com/ee/index.php/news_articles/view/sample_news_article/

20 Feb 2009, 17:25
Ryanirelan_headshot_48x48_pragsmall

Ryan Irelan (218 posts)

OK, a few things:

  • Can you confirm that you have a template group name “news_articles” and a template named “view” ? I know it sounds silly, but sometimes it’s the simplest things.
  • Please paste in the block of code where you’re creating the URL for “Read Story”
21 Feb 2009, 00:36
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

Yep, I have a template group “news_articles” and a template within that “view”


{exp:weblog:entries weblog="news_articles" limit="1" status="Featured Top Story"}
						
						

{title}

By {author}
{article_excerpt}

<a href="{title_permalink="news_articles/view"}" class="read_story">Read Story

{/exp:weblog:entries}
21 Feb 2009, 02:06
Ryanirelan_headshot_48x48_pragsmall

Ryan Irelan (218 posts)

Thanks, Adele. What’s in your @news_articles/view@ template? Can you paste it in here?

21 Feb 2009, 04:54
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

here’s the template name…. Template Name news_articles/view (Last Edit: 02/18/09 06:56 pm by adele the admin)


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">



	

	Engine City Times                                        
	
	
	<!--[if lt IE 7]>
	<link rel="stylesheet" href="css/screen/patches/win-ie-old.css" type="text/css" media="screen, projection" />
	<![endif]-->
	<!--[if gte IE 7]>
	<link rel="stylesheet" href="css/screen/patches/win-ie7-up.css" type="text/css" media="screen, projection" />
	<![endif]-->
	



	
	

Engine City Times

Saturday, May 20, 2007

<!-- END #main-nav -->
<!-- END #masthead -->
{exp:weblog:entries weblog="news_articles" limit="1" status="Open|Top Story|Featured Top Story"} News Article Image

{title}

By {author}
{article_body} {/exp:weblog:entries}
Reader Discussion
{exp:comment:entries weblog="news_articles"} <div class="comment-content {switch="odd|even">
Posted by {name} {comment_date format="%F %d, %Y"}
{comment}
{/exp:comments:entries}
Comment on this News Article

We welcome your comments on this news story. Please complete the form to the left to add to the conversation.

Please Note: Engine City Times editors reserve the right to edit or remove any comment that is deemed inappropriate, off-topic or otherwise violating the Terms of Service of the Engine City Times website.

Thank you for participating in the public dialogue!

<!-- END #disclaimer --> {exp:comment:form}

Name

Email Address

Comment
{comment}

{/exp:comment:form}
<!-- END #comment-form -->

Related Articles

Quis Nostrud Exercitation Ullamco

By Bob Smith

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

Read Story

Quis Nostrud Exercitation Ullamco

By Bob Smith

Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum

Read Story

Quis Nostrud Exercitation Ullamco

By Bob Smith

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

Read Story

<!-- END #related-articles -->
<!-- END clear -->
<!-- END #content --> <!-- END #topic-nav -->
<!-- END clear -->
<!-- END clear -->

© 2007 Engine City News

<!-- END #footer --> <!-- END #layoutWrapper -->
21 Feb 2009, 17:04
Ryanirelan_headshot_48x48_pragsmall

Ryan Irelan (218 posts)

OK, that all looks good. I noticed that you’re running EE in a subdirectory (@/ee@). Can you also paste in your entire @.htaccess@ file contents. I think that might be the culprit and a simple fix.

21 Feb 2009, 23:31
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

oi – I’m using godaddy for hosting right now; and so I’m not seeing my .htaccess file… I know that I’m able to use .htaccess with my hosting account… excuse my ignorance, but is this a file that I can just create and then upload?… thanks Ryan for all your help with this.

22 Feb 2009, 01:38
Ryanirelan_headshot_48x48_pragsmall

Ryan Irelan (218 posts)

OK, actually it looks like you’re not trying to remove the index.php from the URL. I’m not sure what is going on. Everything you have looks correct to me and should work. I’m not sure why it isn’t, however.

If you’d like to create an admin account in your EE control panel and email me (ryan AT mijingo.com) the login information, I’d be happy to take a look. But from what you’ve posted here, I’m not sure why you site isn’t working properly.

22 Feb 2009, 22:22
Wilson_pragsmall

Adele Wilson-Hamaker (7 posts)

Hi Ryan – I just emailed you access to my cp…. thanks!

06 Nov 2009, 16:54
N503588997_7372_6030_pragsmall

Charles Carter (4 posts)

Was there a solution for this one? I am having the same issue. My index.php page is linking to an index.php without css formatting instead of the view.php page. The view.php page is in the news_articles folder and the title_permalink is directing to the view.php page, however it is going to the non-formatted index.php page.

  You must be logged in to comment