Announcement

Collapse
No announcement yet.

Can PHP be used on web pages

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can PHP be used on web pages

    I am adding a news feed to my site where news will be added automatically, however, I understand that this will need Actinic to utilise PHP.

    The following is what I have been asked to provide:-
    Provide some code to allow you to add the latest news to pages of your site within Actinic (as long as they can be adjusted to support PHP

    Can anyone advise me whether this will be possible.

    Thanks.
    Robin Antill - Fan of Actinic.https://community.sellerdeck.com/cor...lies/smile.gif My Site 1st Choice Leisure Buildings

    #2
    The Actinic software by default uploads .html pages, which would not be parsed by your web server for php content, plus the checkout is perl, so would not be able to parse any php content at all.

    I would ask if they have a java script version you could use to pull it, although in some codeing conditions you can use php in the pages, when pages are served with the .php ending, which others who have done this might be able to explain in more detail.

    Comment


      #3
      Thanks for the quick reply. I will put it forward to the company implementing the news pages.

      Is it possible that the Actinic pages could be .php instead of .html?

      Thanks.
      Robin Antill - Fan of Actinic.https://community.sellerdeck.com/cor...lies/smile.gif My Site 1st Choice Leisure Buildings

      Comment


        #4
        You can change the page name to end in .php for all pages within the content tree (manually), but again need to stress that if you incorporate a php script into your design and then the cart processes, then it wont work, if you however create a design for php displaying pages (that has your php feed) and then another for all other pages (search, add to cart, checkout and so on) which does not have the php in its code, then I dont see why not, but like I say, easy life would be to pull using js if at all possible, then dont have to worry about anything really...

        Comment


          #5
          Hi,
          Thanks for that. I don't wish to have to change all pages manually so I will have to see what the programmers come up with.
          Thanks again.
          Robin
          Robin Antill - Fan of Actinic.https://community.sellerdeck.com/cor...lies/smile.gif My Site 1st Choice Leisure Buildings

          Comment


            #6
            You could parse your .html pages as .php using .htaccess. Something like (untested)

            Code:
            AddType application/x-httpd-php .htm .html
            should do it. I've used this on a couple of Actinic sites and it works very well.
            Cheers

            David
            Located in Edinburgh UK

            http://twitter.com/mcfinster

            Comment


              #7
              Hi Dave,
              That's looks brilliant. I will give it a try, thank you.
              Robin
              Robin Antill - Fan of Actinic.https://community.sellerdeck.com/cor...lies/smile.gif My Site 1st Choice Leisure Buildings

              Comment


                #8
                you might find that wont work on all servers, Dave is correct but i have found you might need to tweek things a little to get it to work

                You might find your host does not allow parsing html as php aswell, not all do as it adds a little load to the server

                Comment


                  #9
                  I am adding a news feed to my site
                  You didn't say if this is for one page, a few pages, or every page.

                  If one or a few pages, you'll be able to set the page name to .php and the job is done.

                  If every page, you'll have to use Conditions so that the code isn't used on the Perl based pages. E.g. Cart, Checkout, Search Results.

                  A final thing to note is that if it's shown on a Product page, then these pages can be displayed via Perl scripts if they're located using the Search facility and you have Highlight Located Text set within Settings / Search Settings / Results. This will break your PHP. The simple cure is to uncheck the Highlight Located Text setting.
                  Norman - www.drillpine.biz
                  Edinburgh, U K / Bitez, Turkey

                  Comment


                    #10
                    Hi,
                    Thanks for the advice.
                    I do intend the news items will be on all the pages with the exception of the perl based pages. I have a special template which I use on my shop and brochure pages so this should work OK. Thanks for telling me what I need to do with the Search pages, it is appreciated and is something I would not have thought of.
                    Regards,
                    Robin
                    Robin Antill - Fan of Actinic.https://community.sellerdeck.com/cor...lies/smile.gif My Site 1st Choice Leisure Buildings

                    Comment

                    Working...
                    X