Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3303912
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T21:00:23+00:00 2026-05-17T21:00:23+00:00

I am working on an existing website that uses Zend Framework, and I am

  • 0

I am working on an existing website that uses Zend Framework, and I am trying to avoid hard-coding content that needs to be dynamic in nature.

I have a list of articles that need to be output as links with or without a description. Each link generates a dynamic page that will output the full article with a breadcrumb and a link list of the other article titles, saving state to highlight the current article. I have a template ready to take each variable, but first I need a content source.

Because the list is somewhat short, we do not feel it should be stored in the database (how would I even enter/edit said content in the database without a CMS?).

Can this be done by parsing an XML document, or is there another method I am not thinking of? I’ve used SimpleXML on non-Zend PHP sites but calling the class directly doesn’t seem to work (I think it might be a path issue).

EDIT: I ended up using the solution recommended by prodigitalson:

I created an XML file for my content’s meta data (title, hash, description, include file) and put it in my app/modules/default/model folder. I then laid out each full article as an include snippet, and put the files in views/partials. I created a custom class with the methods I needed and put it in my library folder — then, I instantiated my class in the controller’s init() method. Then, the object was available to all pages/actions within that controller.

Then, I can call any method from the controller-instantiated object in a corresponding view. I’m able to output links, full articles and everything else I need by using this approach. I’m passing the current URL param (hash) to the class before outputting the link list in order to highlight the current link.

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T21:00:24+00:00Added an answer on May 17, 2026 at 9:00 pm

    Id probably stick with XML (or ini if you prefer) to store the meta info for the articles (path to html file, nav title, url/url params).Then instead of SimpleXML id use Zend_Config_Xml (or ini). to pull int he info. From there it shoudl jsut be a matter of pulling the varibales you need out of it and including the actual content file (which i would keep completely separate from the config – just store the path to the “content” file).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We are a team of many developers working on a website that uses both
I'm working on an existing large site that uses querystings in ID for different
I'm working on an existing custom control for an existing website that has to
So I'm currently working on rebuilding an existing website that is used internally at
I am working with an existing ASP.NET/C# website that has a new requirement: when
Currently I am working on an existing website that was initially created using SMF
I'm working on a website that uses lots of png24 files, for transparency. I
I am working on integrating my pre existing website into a RoR framework. So
I've added in the Dynamic Data stuff to our existing website, and gotten that
I'm working on an existing magento web site that is in french. The link

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.