We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 8416
    • 173 Posts
    Hi,
    When I add a Blog entry using the code below, the blog get created but it can’t be displayed (get a 404 error) because the link generated is the id of the new blog created appended with html (.../106.html) instead of being the document alias (.../article-1199467847.html) when the URLF is turned on. URF works fine for the other documents. Does anybody knows how to generate the proper link for a blog entry with URLF?
    Thank you for your help.

    [!NewsPublisher? &folder=`2` &canpost=`Blog Admins` &formtpl=`FormBlog` &footertpl=`Comments` &makefolder=`1` &rtcontent=`tvblogContent`!]
      • 4310
      • 2,310 Posts
      This is my call...
      [!NewsPublisher? &folder=`2` &canpost=`Site Admins` &formtpl=`FormBlog` &footertpl=`FormBlogComments` &makefolder=`1` &rtcontent=`tvblogContent` &clearcache=`1` !]

      As long as I publish it both the 212.html or article-1199489239.html url’s work.
      Have you got a standard .htaccess file?

      David
        • 8416
        • 173 Posts
        humm it still doesn’t work.

        This is what I have in my .htaccess

        # The Friendly URLs part
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ /MyProject/index.php?q=$1 [L,QSA]

        Thanks for any pointers....
          • 4310
          • 2,310 Posts
          Are all the tpl chunks standard?
          You could try adding this to the snippet call
          &aliastitle=`1`

          which would force the page title to become the alias.
          This would help see if it’s a problem with the creation of the article & time stamp combination.

          David
            • 8416
            • 173 Posts
            Thanks. I tried the alias to no avail. Something wierd is happening though. I can see my blog entry document created in the manager but the document’s status is unpublished. Is it a problem?
            Thanks

            Eric
              • 4310
              • 2,310 Posts
              Eric,
              Are you setting the published date?
              Looking at the code within NewsPublisher, if the publish date is greater than the created on date the document is set to be unpublished.
              When I had the documents set to unpublished I couldn’t access them via the url.
              Have you looked in the database to see what the alias/published status is?

              David
                • 8416
                • 173 Posts
                Thanks for your support. That helped...

                Eric
                  • 4310
                  • 2,310 Posts
                  Glad I could help!

                  David