Page 2 of 3

Re: Categories In News Module

Posted: Thu Aug 02, 2012 10:24 pm
by calguy1000
Also, I never upgrade a new version without waiting a month and checking the boards for issues. That's why I'm here a lot these days.
You know... we had a beta program. Ran for a month and a half.

When a 6 week beta program ends and I see unverifiable, non-reproducible, vague problems such as this I am not in any real hurry to try to investigate them either.

Re: Categories In News Module

Posted: Fri Aug 03, 2012 8:51 am
by uniqu3
carasmo wrote:Also, I never upgrade a new version without waiting a month and checking the boards for issues. That's why I'm here a lot these days.
Cool, let other people do the work in Beta process. So much about community effort.
LAME!

Re: Categories In News Module

Posted: Fri Aug 03, 2012 11:33 am
by swarfega
calguy1000 wrote:
Also, I never upgrade a new version without waiting a month and checking the boards for issues. That's why I'm here a lot these days.
You know... we had a beta program. Ran for a month and a half.

When a 6 week beta program ends and I see unverifiable, non-reproducible, vague problems such as this I am not in any real hurry to try to investigate them either.
I'd be very loathe to use unstable software on my main website. That's ridiculous to suggest that.

Right now the page section in control panel is unuseable and I'm not seeing constructive input here.

Re: Categories In News Module

Posted: Fri Aug 03, 2012 11:37 am
by uniqu3
Nobody suggested to use "unstable" Software on a Production site.

Re: Categories In News Module

Posted: Fri Aug 03, 2012 2:40 pm
by carasmo
A beta program is not enough for me, I have a child, a mother with brain cancer, and hardly any time to work on work after losing nearly a year without anything and moving back from CA to FL to take care of her. Now that I can work, I can't spend any extra time with testing and dealing with issues.

There's plenty of ways to support a project like CMSMS without beta testing, such as 500.00 ways the past 12 months. Not a lot, but almost as much as 2 copies of Expression Engine, which I'm probably switching to in the near future.

Re: Categories In News Module

Posted: Fri Aug 03, 2012 8:44 pm
by Dr.CSS
If you feel that the page or admin isn't working because of something you inserted in the page content and can't get to the page now to edit it then you may need to go to the DB and remove it there...

Re: Categories In News Module

Posted: Thu Aug 09, 2012 2:53 pm
by swarfega
The support team at the hosting company seemed to think that the missing news categories and non-working news post links on the news page might be down to the htaccess file.

Here I post the various code blocks I am using:

• .htaccess file:
ErrorDocument 404 /cms/index.php?page=error404

<IfModule php5_module>
php_value include_path /ZendGdata
</IfModule>

# ------------------------
# BEGIN Optional settings

Options -Indexes
Options +FollowSymLinks
DirectoryIndex /cms/index.php
RewriteBase /cms
RewriteEngine on
#RewriteOptions inherit
#SecFilterEngine Off

#RewriteCond %{SCRIPT_FILENAME} !-f
#RewriteRule !^cms(/?|/.+)$ /cms%{REQUEST_URI} [L]

#Adds .thriplow to categories
RewriteCond %{HTTP_HOST} ^thriplow.org.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.thriplow.org.uk$
#RewriteRule ^news/category/([0-9]+)/(.+) index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59 [NC,L]
RewriteRule ^cms/category/([0-9]+)/(.+).thriplow index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59 [NC,L]

# 301 Redirect all requests that don't contain a dot or trailing slash to
# include a trailing slash
# except for form POSTS
RewriteCond %{REQUEST_URI} !/$
RewriteCond %{REQUEST_URI} !\.
#RewriteCond %{REQUEST_METHOD} !POST$
RewriteRule ^(.*) %{REQUEST_URI}/ [R=301,L]

#Rewrites urls in the form of /parent/child/
#but only rewrites if the requested URL is not a file or directory
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+).thriplow$ index.php?page=$1 [QSA]
• config.php file:
<?php
# CMS Made Simple Configuration File
# Documentation: /doc/CMSMS_config_reference.pdf
#
$config['php_memory_limit'] = '100000000';
$config['process_whole_template'] = '';
$config['debug'] = false;
$config['output_compression'] = '';
$config['timezone'] = 'Europe/London';
$config['dbms'] = 'mysql';
$config['db_hostname'] = 'localhost';
$config['db_username'] = '****';
$config['db_password'] = '****';
$config['db_name'] = 'nexus';
$config['db_port'] = 0;
$config['db_prefix'] = 'cms_';
$config['persistent_db_conn'] = '';
$config['use_adodb_lite'] = '1';
$config['root_url'] = 'http://thriplow.org.uk/cms';
$config['ssl_url'] = 'https://thriplow.org.uk/cms/';
$config['root_path'] = '/var/www/vhosts/thriplow.org.uk/httpdocs/cms';
$config['admin_dir'] = 'admin';
$config['previews_path'] = '/var/www/vhosts/thriplow.org.uk/httpdocs/cms/tmp/cache';
$config['uploads_path'] = '/var/www/vhosts/thriplow.org.uk/httpdocs/cms/uploads';
$config['uploads_url'] = 'http://thriplow.org.uk/cms/uploads';
$config['default_upload_permission'] = '664';
$config['use_smarty_php_tags'] = '';
$config['auto_alias_content'] = true;
$config['url_rewriting'] = 'mod_rewrite';
$config['page_extension'] = '.thriplow';
$config['query_var'] = 'page';
$config['image_manipulation_prog'] = 'GD';
$config['image_transform_lib_path'] = '/usr/bin/ImageMagick/';
$config['image_uploads_path'] = '/var/www/vhosts/thriplow.org.uk/httpdocs/cms/uploads/images';
$config['image_uploads_url'] = 'http://thriplow.org.uk/cms/uploads/images';
$config['ssl_uploads_url'] = '/uploads';
$config['locale'] = 'en-gb';
$config['default_encoding'] = 'utf-8';
$config['admin_encoding'] = 'utf-8';
$config['set_names'] = true;
$config['wiki_url'] = 'http://wiki.cmsmadesimple.org/index.php ... dmin_Panel';
?>
• News page:
{cms_module module="TruetypeText" style="Welcome" text="News"} <span class="text">{news browsecat="0" moretext="[ more ]" number="5" browsecattemplate="thriplow3"}</span>
• News Summary Template:
<!-- Start News Display Template -->

{if $pagecount > 1}
<p>
{if $pagenumber > 1}
{$firstpage}&nbsp;{$prevpage}&nbsp;
{/if}
{$pagetext}&nbsp;{$pagenumber}&nbsp;{$oftext}&nbsp;{$pagecount}
{if $pagenumber < $pagecount}
&nbsp;{$nextpage}&nbsp;{$lastpage}
{/if}
</p>
<br />
{/if}
{foreach from=$items item=entry}
{if $smarty.get.selectedauthor!= ""}{capture assign="selectedauthor"}{$smarty.get.selectedauthor}{/capture}{/if}
{if $selectedauthor}{capture assign="newsauthor"}<a href="{$root_url}news?selectedauthor={$entry->author|escape:'htmlall'}" class="postby">{$entry->author|escape:'htmlall'}</a>{/capture}{/if}
{capture assign="newsitem"}

<div id="bloginfo2">
<table cellpadding="2" style="width: 100%">
<tr>
<td colspan="4" class="posttitle2"><table><tr><td valign="top"><img src="/cms/images/newsicons/page_green.png" border=0></td><td><span class="text"><strong><a class="links3" href="{$entry->moreurl}" title="{$entry->title}">{$entry->title|cms_escape}</a></strong></span></td></tr></table></td>
</tr>
<tr>
<td><span class="postby"><img src="/cms/images/newsicons/calendar_view_day.png" border=0>&nbsp;{$entry->postdate|cms_date_format:"%d"}-{$entry->postdate|cms_date_format:"%b"}-{$entry->postdate|cms_date_format:"%Y"}</span></td>
<td><img src="/cms/images/newsicons/tag_green.png" border=0>&nbsp;<span class="postby">{$entry->category}</span></td>
<td>{if $entry->author}<img src="/cms/images/newsicons/vcard.png" border=0>&nbsp;<span class="postby"><a href="{$root_url}/news.thriplow?selectedauthor={$entry->author|escape:'htmlall'}" class="postby">{$entry->author|escape:'htmlall'}</a></span>
{/if}</td>
<td>&nbsp;</td>
</tr>
</table>
</div>

{if $entry->summary}
<div class="NewsSummarySummary"><br />
<table cellpadding="0" style="width: 95%;margin: 0 auto;">
<tr>
<td class="lbq" style="width: 1px" valign="bottom">&nbsp;</td>
<td class="cbq" style="width: 100%">
<table cellpadding="10" style="width: 100%">
<tr>
<td class="summerycontent">{eval var=$entry->summary}<br /></td>
<td class="rbq" valign="top" style="width: 30px;height: 100%">{cms_module module="TruetypeText" style="quote" text="”"}</td>
</tr>
</table>
</td>
</tr>
</table>

</div>

<div class="NewsSummaryMorelink">
<div id="bloginfo2c" align="center"><spam class="text">{$entry->morelink}</spam>
<br />
</div>

{else if $entry->content}

<div class="NewsSummaryContent">
<spam class="text">{eval var=$entry->content}</spam></div><br />
<div id="bloginfo2d">&nbsp;</div>
</div>
{/if}

{if isset($entry->extra)}
<div class="NewsSummaryExtra">
{eval var=$entry->extra}
{* {cms_module module='Uploads' mode='simpleurl' upload_id=$entry->extravalue} *}
</div>
{/if}
{if isset($entry->fields)}
{foreach from=$entry->fields item='field'}
<div class="NewsSummaryField">
{if $field->type == 'file'}
<img src="{$entry->file_location}/{$field->value}"/>
{else}
{$field->name}:&nbsp;{eval var=$field->value}
{/if}
</div>
{/foreach}
{/if}

<div id="hrline" style="align:center">&nbsp;</div><br />
</div>
{/capture}
{if $selectedauthor}
{if $newsauthor === $selectedauthor}{$newsitem}{/if}
{else}
{$newsitem}
{/if}
{/foreach}


{if $pagecount > 1}
<p>
{if $pagenumber > 1}
{$firstpage}&nbsp;{$prevpage}&nbsp;
{/if}
{$pagetext}&nbsp;{$pagenumber}&nbsp;{$oftext}&nbsp;{$pagecount}
{if $pagenumber < $pagecount}
&nbsp;{$nextpage}&nbsp;{$lastpage}
{/if}
</p>
{/if}

<!-- End News Display Template -->
• News Detail Template:
{* set a canonical variable that can be used in the head section if process_whole_template is false in the config.php *}
{if isset($entry->canonical)}
{assign var='canonical' value=$entry->canonical}
{/if}

<div id="bloginfo2">
<table cellpadding="2" style="width: 100%">
<tr>
<td colspan="4" class="posttitle2"><table><tr><td valign="top"><img src="/cms/images/newsicons/page_green.png" border=0></td><td><span class="text"><strong>{$entry->title|cms_escape}</strong></span></td></tr></table></td>
</tr>
<tr>
<td><span class="postby"><img src="/cms/images/newsicons/calendar_view_day.png" border=0>&nbsp;{$entry->postdate|cms_date_format:'%d'}-{$entry->postdate|cms_date_format:'%b'}-{$entry->postdate|cms_date_format:'%Y'}</span></td>
<td><img src="/cms/images/newsicons/tag_green.png" border=0>&nbsp;<span class="postby">{$entry->category}</span></td>
<td>{if $entry->author}<img src="/cms/images/newsicons/vcard.png" border=0>&nbsp;<span class="postby">{$entry->author}</span>
{/if}</td>
</tr>
</table>
</div>

{eval var=$entry->content}
<br />
<div id="bloginfo2b"><table><tr><td><span class="text">{if $return_url != ""}
<img src="/cms/images/newsicons/page_go.png" border=0>&nbsp;{$return_url}{if $category_name != ''} - {$category_link}{/if}
{/if}</span></td>
<td valign="right" style="width:50%">&nbsp;&nbsp;{cms_module module='PDFGenerator' src_img='/cms/images/newsicons/page_white_acrobat.png' includetemplate='false' subsystem="mpdf"}{cms_module module='printing' showbutton='true'}{socialBookmarking submitto='twitter|facebook|email' img_size='small'}</td>
</tr>
</table><br />
<table>
<tr>
<td>
<div id="disqus_thread"></div>
<__script__ type="text/javascript">
/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
var disqus_shortname = 'thriplowvillagewebsite'; // required: replace example with your forum shortname

/* * * DON'T EDIT BELOW THIS LINE * * */
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</__script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a></td>
</tr>
</table>

{if $entry->extra}
<div id="NewsPostDetailExtra">
{$extra_label} {$entry->extra}
</div>
{/if}
</div>

{if isset($entry->fields)}
{foreach from=$entry->fields item='field'}
<div class="NewsDetailField">
{if $field->type == 'file'}
{* this template assumes that every file uploaded is an image of some sort, because News doesn't distindguish *}
<img src="{$entry->file_location}/{$field->value}"/>
{else}
{$field->name}:&nbsp;{eval var=$field->value}
{/if}
</div>
{/foreach}
{/if}
• News Browse Category Template:
{if $count > 0}
<ul class="list1">
{foreach from=$cats item=node}
{if $node.depth > $node.prevdepth}
{repeat string="<ul>" times=$node.depth-$node.prevdepth}
{elseif $node.depth < $node.prevdepth}
{repeat string="</li></ul>" times=$node.prevdepth-$node.depth}
</li>
{elseif $node.index > 0}</li>
{/if}
<li class="newscategory">
{if $node.count > 0}
<a href="{news_category_url name=$node.news_category_name id=$node.news_category_id}">{$node.news_category_name}</a> ({$node.count}){else}<span>{$node.news_category_name} (0)</span>{/if}
{/foreach}
{repeat string="</li></ul>" times=$node.depth-1}</li>
</ul>
{/if}
• Custom UDT (mews_category_url):
$name = preg_replace(array('/ /', '/[^A-Za-z0-9-\-]/', '/--/'),array('-', '', '-'),$params['name']);
$id = $params['id'];
echo 'category/'.$id.'/'.$name.'.thriplow';
Sorry for long post but I feel that I need to get this sorted. Thanks in advance for any help.

Re: Categories In News Module

Posted: Thu Aug 09, 2012 3:05 pm
by carasmo
You added custom .htaccess code regarding categories. Remove all custom stuff everywhere and see what happens. Check the actual paths that you are re-writing in the htaccess, I bet they changed.

Re: Categories In News Module

Posted: Thu Aug 09, 2012 3:17 pm
by swarfega
I wonder whether its this line:
RewriteRule ^cms/category/([0-9]+)/(.+).thriplow index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59 [NC,L]
and I wonder if the url has changed with version 1.11 but Im not sure how Id find out what the correct url would be.

Re: Categories In News Module

Posted: Thu Aug 09, 2012 3:22 pm
by carasmo
by removing it and replacing the category template with the default, then clicking a generated link from that list and seeing what the url is.

Re: Categories In News Module

Posted: Thu Aug 09, 2012 3:55 pm
by Jos
swarfega wrote:I wonder whether its this line:
RewriteRule ^cms/category/([0-9]+)/(.+).thriplow index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59 [NC,L]
and I wonder if the url has changed with version 1.11 but Im not sure how Id find out what the correct url would be.
Where did you read that you should add this to you htaccess anyway?

Re: Categories In News Module

Posted: Thu Aug 09, 2012 4:06 pm
by swarfega
Ok heres the url of a post. I hope that helps in the diagnostics. To me it looks like the format has changed in 1.11.

http://thriplow.org.uk/cms/index.php?ma ... turnid=137

Re: Categories In News Module

Posted: Thu Aug 09, 2012 4:19 pm
by swarfega
Jos wrote:
swarfega wrote:I wonder whether its this line:
RewriteRule ^cms/category/([0-9]+)/(.+).thriplow index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59 [NC,L]
and I wonder if the url has changed with version 1.11 but Im not sure how Id find out what the correct url would be.
Where did you read that you should add this to you htaccess anyway?
I read it in some post here on the forum.

Re: Categories In News Module

Posted: Thu Aug 09, 2012 4:23 pm
by carasmo
Find that original thread and ask for help there on the new way it's done in 1.11

Re: Categories In News Module

Posted: Thu Aug 09, 2012 4:30 pm
by swarfega
I have that line and block of code currently disabled but the links still dont work.