Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    CodeIgniter Prototype (WAS: PFSense Logo to print)

    Scheduled Pinned Locked Moved Development
    23 Posts 7 Posters 13.4k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      DanielSHaischt
      last edited by

      Regarding representing GUI elements as XML…

      pfSense is already following that approach. Tho the XML used by pfSense to represent a GUI isn't correct XML. Thus if using a validating XML parser, the parser would spit out tons of error messages.

      So the goal is to ...

      • Define an XML schema that is XML conform  (i.e. it validates)

      • A schema can be implemented using a DTD, XML schema or RelaxNG

      • Any of the above schema types requires to use libxml2 instead of expat

      • Create over time different views where each view outputs specific GUIs such as XHTML based DHTML, simple XHTML without JavaScript that can be rendered by a text browser or even views that are able to generate ncurses or similar console GUIs

      Please read: http://wiki.pfsense.com/wikka.php?wakka=GoogleSoCIdeas. There I described some of the above ideas a little further.

      And 'no' pfSense is not participating in Google's SoC  ;)

      Cheers
      Daniel S. Haischt

      Mit freundlichen Gruessen / With kind regards
      DAn.I.El S. Haischt

      1 Reply Last reply Reply Quote 0
      • S
        simoncpu
        last edited by

        ReST or REST whatever… hehehe.  Oki, REST that is. ;D

        I'm not really sure if CodeIgniter has a built-in support for RESTful web services, but we may be able to design our architecture so that it will be as RESTful as the CI framework would allow.

        I've been googling for info, and I found out that we can't really use the four HTTP verbs for our design.  We can use GET for retrieving and POST for adding, updating, and deleting data; however, PUT and DELETE isn't really practical, because as far as I know, PHP (as of version 5) doesn't yet support $_PUT and $_DELETE.  Although this can be solved by using JavaScript at the client side and by inspecting $_SERVER['REQUEST_METHOD'] at the server side, this is at best a kludgey solution.  I would opt for the simplest and cleanest solution– using GET for reading and POST for writing.

        With regards to the XML schema, I'll google for more info about that since I'm currently not that well-versed with XML. ;D

        [ simon.cpu ]

        1 Reply Last reply Reply Quote 0
        • D
          DanielSHaischt
          last edited by

          Hi,

          I did a research regarding PHP-based REST framweworks. Cause I am at work and thus do not have access to my bookmarks I won't be able to provide a link. I'll try to paste a link ASAP…

          What I found so far:

          http://tonic.sourceforge.net/docs/
          http://wiki.jonnay.net/bunny/meditation/meditation (from 2006!)
          http://giantrobots.thoughtbot.com/2007/4/2/jester-javascriptian-rest
          http://www.csscripting.com/wiki/index.php?title=Freja (MVC related)

          Regards
          Daniel S. Haischt

          Mit freundlichen Gruessen / With kind regards
          DAn.I.El S. Haischt

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.