Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Avantgo and Boards

Comments

  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    The layout of Boards.ie would have to be amended for the channel as it's very table dependant and last time I created an AvantGo channel [1], it didn't support tables.

    Also, for replies, forms would have to be handled somewhat differently as AvantGo will only submit them upon upon a sync.

    Finally, how many boards would you want to sync? I could see it bloat my AvantGo PDB before long...

    [1] Plug: ****.net ;)


  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    aye
    i noticed that after posting it
    works well for some sites.........
    /me wonders will it work for the aertel pages???????????


  • Registered Users, Registered Users 2 Posts: 4,676 ✭✭✭Gavin


    aye, I was contemplating writing a perl script to download boards.ie, selected forums etc, and stick it on your palm. Wouldn't be very hard to do i don't think.

    Gav


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by Verb
    aye, I was contemplating writing a perl script to download boards.ie, selected forums etc, and stick it on your palm. Wouldn't be very hard to do i don't think.
    Very do-able in Perl, methinks - or anything that uses or regular expressions. Form submissions could still be a little bit tricky, mind you.

    Given this, were it part of board.ie propper, it might be an idea to keep the architecture consistant and write it in PHP.

    It wouldn't be a major step to allow one to customize which and how many of the boards also, adding say 20k per board to the autochannel's max parameter.

    Hmmm...


  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    If you want to do this I'll support it... would be fun to do and I wouldnt mind learning the PHP necessary to submit SQL and format it...

    DeV.


  • Advertisement
  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by DeVore
    If you want to do this I'll support it... would be fun to do and I wouldnt mind learning the PHP necessary to submit SQL and format it...
    There's actually no need for SQL to come into it, after all AvantGo are storing your prefrences.

    A HTML page allowing one to confiure your link to the AvantGo Autochannel application (prefrences held in as part of a querystring, perhaps), would be first. There would have to be limits on how many threads are pulled down. Next you want to use AvantGo to grab the data over HTTP, or from MySQL directly, fomatting it into something that's AvantGo friendly. Finally, forms for replies - these may be very basic, or could be jazzed up using AvantGo's own POD platform (distantly related to client-side JavaScript for AvantGo).

    I'd be on to do some of this, but only some of it. If others (2 - 4) are willing to take on some of the work too, no probs. PHP skills needed, I can advise on the AvantGo stuff.


  • Registered Users, Registered Users 2 Posts: 4,676 ✭✭✭Gavin


    Aye, I'm fairly familiar with php/avantgo/mysql stuff. I can do it. I don't think it will actually be very hard...

    Is it possible to get a free copy, personal edition type thing, of vbulletin, i can stick on machine at home for testing ?

    Gav


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by Verb
    Is it possible to get a free copy, personal edition type thing, of vbulletin, i can stick on machine at home for testing ?
    I think vBulletin itself is fairly immaterial here, a copy of the MySQL schema is more important.

    If we can get 1 - 2 more, I suspect we'll be able to go forward with this.


  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    I can provide you with a schema no problem and we could create another board under Admin specifically for hacking Boards.ie in this sort of fashion.

    I'd like people to be able to get their personalised Boards.ie feeds both on the front page and through avantgo.

    I'm hella busy at the moment but I can certainly help with a fair bit of the planning and implementation.

    DeV.


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    I was thinking that tackling boards by allowing members to view their subscribed threads, forums and PM's from their Control Panel would be the way to go, alright.

    Given this, subscribed forums would bloat most PDA's, while PM's raise the unnerving issue of security (a username/password would in effect have to pass via the AvantGo proxy as clear-text). So, in the sake of simplicity, I'd suggest tackling subscribed threads first.

    Application would probably have to be split into three parts:
    1. A link in a users control panel, allowing them to subscribe, generating the necessary AvantGo URL,
    2. Scripts to read the preferences (either from the DB directly of encoded in the Avantgo URL) and format the threads for AvantGo (data coming directly from the DB), and
    3. A post/reply script, which would also have to bypass the 'constructing a new page' page

    The first is easy once an architecture is decided. Database schemas, with some sample data (for example; we don't know if the vB code is stored in the database and formatted on the fly or formatted upon INSERT), would be needed for both the User prefs and tread content side of things.

    Unfortunately, I'm also pretty busy at present and while I'm more than happy to sacrifice a day on a weekend, I've no intention of doing the whole thing alone (community spirit does not pay for my vices ;) ). As Verb is the only other volunteer for coding and DeVore has offered to do some implementation (deployment?), I don’t think there’s enough here to make it fly, at least for me. Another two would probably do it, as long as the workload was spread out.


  • Advertisement
  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    The data is held in a database and formatted on retrieval which is nice.

    The system already allows for you to subscribe to a thread so that interface is written. What isnt there is the extraction script and formatting for the Avantgo bot.

    This is why I presumed we'd be writing SQL at some stage and I'm happy to do that...

    I dont think it will take more then the three of us to do it to be honest, the DB structure is already there.

    Verb knows how to execute the SQL in PHP (as I'm sure you could too). You know the avantgo bot and the scripting to make it nice for that. I know the Boards DB archetecture and the SQL to get someone's subscribed threads.

    I think we can simply ignore posting for the moment and get *that* much done.

    I'll be up front about this: Even though I know both of you guys whatever code is written would have to be signed over to Boards Ltd. I dont want any clever clogs infecting us with a open-source style license (or worse) later down the line. Sorry to be paranoid but better that then in court!

    DeV.


  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    Oh, found you can subscribe to forums too... so
    we could read off the forums the person is subscribed to and provide the list of last 10 threads posted to in an Avantgo friendly fashion.
    Nice!

    I'm looking into the SQL at the moment... hopefully its not too hairy... feckin MYSQL...ick...

    DeV.


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by DeVore
    What isnt there is the extraction script and formatting for the Avantgo bot.
    If we can get the subscribed threads using only the user ID, then I can quickly write you the necessary code.
    This is why I presumed we'd be writing SQL at some stage and I'm happy to do that...
    [/B]
    Am I right in thinking that it’s all stored in MySQL? If so the SQL will be part of the PHP script (no stored procedures). However, I’d suggest, if you want to tackle the SQL, to do so as a series of functions in an SSI that can be drawn upon by myself and Verb (assuming he’s still on for it). You won’t need much PHP for that – also means that I won’t have to worry about your DB schema.
    I dont think it will take more then the three of us to do it to be honest, the DB structure is already there.
    [/B]
    If we’re dropping posting for the time being, then I’d agree.
    I'll be up front about this: Even though I know both of you guys whatever code is written would have to be signed over to Boards Ltd. I dont want any clever clogs infecting us with a open-source style license (or worse) later down the line. Sorry to be paranoid but better that then in court![/B]
    LOL. I was wondering how long it would take for that to be raised ;)

    Seriously though - no problem. You won’t be getting any of my existing IP in this and maintenance ain’t my problem.

    I’ll just take payment by way of credit for work done and a few beers :rolleyes:


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by DeVore
    Oh, found you can subscribe to forums too... so
    we could read off the forums the person is subscribed to and provide the list of last 10 threads posted to in an Avantgo friendly fashion.
    Hold on. Think about it... 10 threads, potentially with 100 posts each... My Palm would be very upset (as would my modem when hotsync-ing).

    If you want that, then perhaps each thread should only have perhaps a maximum of the last ten posts. Sounds like a TOP ... date DESC SQL query to me.


  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    its worse then that... 10 subscribed forums -> last 10 thread ->
    20 post each (more realistic)

    2000 posts synched. However its not all bad news.

    Since we'd be using light navigation and only taking out the text (no sigs, avatars, etc)... it shouldnt be too bad.

    say .2 of a k per post
    .2k x 2000 = 400K ... acceptible enough if you are syncing in a cradle. and if its not... drop the number of subscribed forums...

    I can also pull out the latest from when the person was last there, so they wont get the same posts again and again. Hence the situation above would be very worst case.

    DeV.


  • Business & Finance Moderators, Entertainment Moderators Posts: 32,387 Mod ✭✭✭✭DeVore


    ok so I am using some icky SQL like this:

    SELECT
    user.username, subscribeforum.forumid , forum.title

    FROM
    `subscribeforum`,`user`, `forum`

    WHERE
    subscribeforum.userid = 98 and user.userid = 98
    and
    subscribeforum.forumid = forum.forumid


    to pull back
    DeVore 90 Help 
    DeVore 30 Admin 
    

    (I'm user 98 btw)...

    If you overlook the fact that I'm not using inner-joins (I'm using hand coded joins for simplicity)... you can see the type of SQL statement I can create for you guys.

    What you do with this now, I dunno. Thats getting into the realm of how PHP handles recordsets. I like the idea of creating a number of include files that I can work on that perform functions for you... very kinda com-objecty...

    So, I can pull back a list of the forums the person is subscribed to, and I expect, the posts since (s)he was last there....

    I think we can try testing a few bits now...

    DeV.


  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    if i can help just ask - but tbh i've 0 (zip/zilch/nil/null) sql knowledge :(


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by DeVore
    What you do with this now, I dunno. Thats getting into the realm of how PHP handles recordsets. I like the idea of creating a number of include files that I can work on that perform functions for you... very kinda com-objecty...

    You would want to put it in a function something like this:

    [PHP]
    function getSubForums($id) {
    $SQL = "SELECT user.username, subscribeforum.";
    $SQL .= "forumid , forum.title FROM [subscribeforum]";
    $SQL .= ", [user], [forum] WHERE subscribeforum";
    $SQL .= ".userid = ".$id." and user.userid = ".$id;
    $SQL .= " and subscribeforum.forumid = ";
    $SQL .= "forum.forumid";

    $i = 0;
    $rs= mysql_query ($SQL);
    while($row = mysql_fetch_array($rs)) {
    $TempArray[$i] = array (
    "username" => $row["username"],
    "subscribeforum" => $row["subscribeforum"],
    "title " => $row["title"]);
    $i++;
    }
    mysql_close();
    return $TempArray;
    }
    [/PHP]

    Easy ;)

    That way we can seperate the database logic from the display logic and you could put all the necessary SQL functions into an SSI for me (or anyone else) to draw upon and not worry about the database at all (splitting up the work); just the key values of the array being returned and the args needed in the first place.

    You could probably cut and paste that code (warning: I just knocked it up - it's not even slightly tested) for any query. Other SQL operations (such as INSERTS, etc) would be much the same, but only returning a boolean (actually, in this cut down version we wont need any of those).

    Edited 'cos I aready saw a silly mistake in above code


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by MiCr0
    if i can help just ask - but tbh i've 0 (zip/zilch/nil/null) sql knowledge :(
    Do you have PHP?


  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    php knowledge is also a -0 :)


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    /me has a stroke of genuine brilliance*
    look @ the printable version of this thread
    its everything thats needed to get an avantgo readable version of boards.
    with no graphic or links (well except for @ the top)

    --MiCr0





    *this may not be a genuine stroke of brilliance


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Originally posted by MiCr0
    look @ the printable version of this thread
    its everything thats needed to get an avantgo readable version of boards.
    Would probably work, however unless the code was hacked, it won't be optimized for AvantGo and more importantly may cause navigational problems with replies using AvantGo at a later date.

    Also, wouldn't solve the issue of displaying the threads/forums.

    Personally, I'd favour redoing the display code afresh, optimized for AvantGo and extensible for future development, as I suspect the time doing so would probably equate to the time spent hacking the existing code, in the long run. Just an opinion.


  • Registered Users, Registered Users 2 Posts: 4,676 ✭✭✭Gavin


    Sorry I haven't been paying attention of late. things getting busy. Perhaps we move to emails... if we haven't already.. i haven't checked my address up here in a good while...

    gavin at redbrick.dcu.ie

    Gav

    *goes off and has a look at avantgo.com developers part..


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    Probably a good idea that all interested parties meet up to discuss this and move forward on it at this stage.

    Might I suggest, somewhere in D2 over the weekend?

    Email/PM me if interested in getting involved.


Advertisement