Announcement

Collapse
No announcement yet.

Sitephyre & Virtuoso WIP

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

  • Sitephyre & Virtuoso WIP

    I've been working a LOT on bringing these 2 projects forward. For anyone that doesn't know:

    Virtuoso: This is a flash/AIR based display engine that is built on top of my parsing delimiters work. Parsing delimiters is done. There is no reason to continue that thread. I have parsed every delimiter known to man, optimized the parse and can now move on to what that whole thing was intended for in the first place. Basically the language that parsing delimiters created will be the html/css of my display engine. By adding an imported SWC I enable a scripting extension and voila...make anything you can make in flash and AIR but primarily do it with a JSONesque language that I call VON (formerly XXON)

    Sitephyre: This is a content management system that aims to provide every kind of content you can imagine. Kinda like if you stuck together PHPBB3, youTube, Imgur, AnonFiles & OMGPOP (in an example sense). I already was really super duper far on this when I took a break. However, when I went back to it (3 days ago) I decided to change some things.

    I wanted to finally use and understand prepared statements and I now I do and it does. I'm still refining my class but, as it is right now it works very well and is written very clean. I think I can get it cleaner.

    Doing this means that some of the more front end stuff needs to be modified accordingly. I've already started doing this and I find myself completely deleting a lot of stuff and replacing it with much less that does the exact same.

    Instead of taking the original project and running around like a blind chicken trying to edit everything, I just started a new project and bring things from the old project back in a thing at a time. I then edit those things and repeat. This is actually very extensive. I wrote a SHIT LOAD of code. I haven't even started messing with all the javascript I wrote. Right now, my only concern is getting the PHP in order then, I will breeze over the HTML and CSS (cause I don't really want to change any of my display) and finally get the JS in order.


    My desire is to move both of these projects forward simultaneously. Since they are essentially 2 parts of the same monster, I think it's smart to get to a point where they are equally ready to be joined.

    Basically, Sytephyre will handle all of your basic web stuff "The CMS of it all" and Virtuoso will handle Video players, Slideshows, Upload GUI, etc. however, Virtuoso is more like a best-case-scenario type of thing. I will still need to make comparable HTML/CSS/JS "widgets" to the virtuoso ones (where possible) for devices/users that do not allow flash.

    In other words, this is a big honkin deal and if I ever finish this I can finally die in peace (lol). I'm on fire though. I accomplished so much these last three days that my attitude towards this has changed substantially from "hard labor" to "a labor of love". I can say with near accuracy that I spent about +/- 40 hours (in 3 days) on solid programming.

    Prepared statements gave me a bit of a hard time, especially trying to figure out how to handle my multi_query's without making a spaghetti mess. Trying to figure out how to bind_result on wildcard queries was also a bit of a nightmare but, I eventually figured it out. I'm glad I went to the trouble, too. My current code is much more vicious and lean than my previous one was.

    I'll use this thread as a progress thread until I get to a point where Sytephyre is far enough to serve as my blog software. It might not take that long for that actually. The old version was basically already there in a bare bones sense. I just need to piece it back together and modify it on top of the new foundation and I could probably start using it in a beta way.

    That's all for now.

    edit: unlike usual where I will go back to a thread and edit the crap out of it to clean up run on sentences and what-not... I'm just not doing that today. Please excuse my sloppy post. I need to go to sleep so I can wake up with some energy for work tomorrow. You'll have to also excuse me for not being descriptive about code things that many of you may know nothing about. I think I'm getting old or something, I just don't have any desire to explain what prepared statements, multi_query, bind_result, etc is. It's a bunch of PHP stuff and the PHP online manual has excellent descriptions and examples.
    Last edited by MadGypsy; 12-11-2013, 11:05 PM.
    http://www.nextgenquake.com

  • #2
    I had an idea today that I'd like to share with y'all and maybe some of you would like to give your input.

    Audio threads. The premise is simple. It will work (more or less) identical to text threads but it will all be audio. I'm confident I could make some flash widget that would allow recording and have flash encode it as something light like 22k mono. Since this is not music or some other "polished entertainment" I don't really see the need for high quality audio. My opinion is, as long as the audio is clear it should be sufficient. Maybe I could even utilize some simple algorithms for hiss and noise reduction. I have to admit I haven't spent any time messing with audio in flash so, I'm not sure how much I can actually do.

    There is more to think about here, like maybe how often someone can make an audio response, possibly have a user-driven vote system that kills spammers, etc.

    Right now it's just an idea. What do you think about it? Would you enjoy threads that were brought to you more like an audio program that you can participate in? Do you have related ideas or concerns that you think I should consider? Do you maybe know of somewhere else where this idea is already being used, if so, could you provide me with a link?
    http://www.nextgenquake.com

    Comment


    • #3
      This is probably the first thread on the forum I've bookmarked. I'll just say that.


      I can't really think of anything else to say, sorry. :v
      twitch
      wew lad

      Comment


      • #4
        That's all you have to say, you just totally made my day

        I'll tell you a little short story. A decade ago I substituted alcohol with programming. I didn't fill my head up with all of these languages just to make trivial/project type stuff. I want to put my entire education to the test. I want to build something that encompasses everything I know.

        I don't feel like I have any original ideas (mostly) so I'm resigned to remaking unoriginal ones with my own twist/flair. That's what all of this is about. That's also why none of this goes away. Even when I stop it's just a break cause no matter what, I am determined to make all of this knowledge have a "physical" instantiation.

        I've basically just thrown together everything I believe I am capable of creating and called it 1 thing. This conglomeration doesn't really have a static direction or purpose other than to dump my entire education into one big pot of summin.

        I started this almost 4 years ago. However 4 years ago I knew half of what I know now and my education is always growing. 1 second after I posted about audio threads I was already looking for various information on how to build it. I have a bunch of new stuff bookmarked and I'll eventually make audio threads possible even if everyone hates the idea.

        Anyway, that's my little story and the "moral" is: I didn't learn all of this stuff for nothing. I have no choice but to build this or chalk the last decade of my life up to a complete waste, that's on top of the previous decade that was definitely a complete waste (cause I was just drunk and high). I will personally feel a lot better about myself when I have some mega accomplishment under my belt that hilights all of this knowledge I have acquired.
        http://www.nextgenquake.com

        Comment


        • #5
          Well, I replied but I saw you had deleted the second reply. So I'll assume that you thought twice on that one for whatever reason. But good luck.
          twitch
          wew lad

          Comment


          • #6
            I did think twice. I'm just setting myself up to stall my progress BUT, when I have a more solid foundation complete, I would be willing to think a 3rd time and reinstate my offer.

            In the meantime, if my offer was something you were interested in, I would suggest learning some PHP/SQL/HTML/CSS/JS on your own. I can even point you toward a lot of the material that I used.

            There will come a point where it would be nice to have some team members working on some plug-n-play projects.

            One tutorial in particular was very helpful to me for bridging the gap with sql and php. It actually teaches you a bunch of "wrong" stuff (as far as security goes) and it is a bit out-of-date but, it's simplicity is a really good start, in my opinion.

            All you need to get started is xampp and an editor

            Personally, I use the portable min/lite versions of both of those (dump and go).

            Anyway, I have to get back to refining my main database class. I'll make my offer again in the future. I have a bad habit of wanting to do too many things at the same time. I need to start recognizing that before I commit myself to a bunch of stuff that kills my goals. Don't think for a second that I wouldn't enjoy teaching you, though.
            http://www.nextgenquake.com

            Comment


            • #7
              Alrighty, it seemed like quite a hasty offer, but it helps that you've given me a direction to work int.

              I'll get on with it and see what I can do (I'm needing to brush up on my webdesign related skills anyway, so this helps as afaik, every language there will be useful).

              Anyway, I gotta go get on with some work myself actually. Working on a top down shooter which will be my catalyst pretty soon into c++ (using game maker for the whole design aspect, since it uses a scripting language that is just a heavily simplified C++, just like every other engine I've seen lately) and I have college work to do.

              Later
              twitch
              wew lad

              Comment


              • #8
                Hi


                @ MacGyver

                Hey if I undestand you... you would "talk" vs writing so we would listen here in the forum... well I'd like to "hear" that hehe.

                Also when do you plan making a video (youtube) for us to "see" what is this all about.


                @ Omac

                May be because something was rewritten I don't really catch what is going on BUT if you wanna work on something with MacGyver I'd say don't miss this opportunity.
                Last edited by Mom; 12-13-2013, 03:56 AM.

                Comment


                • #9
                  Listen/talk yes but not in this forum

                  @fake youTube - much of this is complete (to some degree) the "delay" is I have to bring my flash engine (virtuoso) up to a level that can provide all the functions. If I was just going to make a regular old flash vid player I could do it in 1 day. Actually I could do it in 1 second cause I already built that long ago.

                  @confusion - I saw Omac's interest and it dawned on me that he might want to be a part of this. Originally I offered to teach him with the stipulation that his education would have to be put toward some end of this project. As much as I would love to do that, I spoke too soon. How can I ever expect to get this moving if I'm dedicating a bunch of time to teaching? I withdrew my offer maybe an hour after I issued it.

                  When I have a more solid foundation and have established a direction, I will reissue my offer but, instead of generically teaching these languages, I will teach him the ins and outs of my project. This is assuming he still has an interest and/or time at that point.
                  http://www.nextgenquake.com

                  Comment


                  • #10
                    Well, I have definitely made progress. Currently, you can register, sign-in/out, post, reply, edit & recent posts. I also have my views system working.

                    My system for views is a bit different than the norm. A view can only be incremented if the current version of the page content is different than the last time you viewed it. So lets say the content had a post and 2 replies. You could refresh the page til your keyboard breaks it is not going to increment the view for you again unless another reply is made or the original post content has changed. I can even capture this data with some accuracy for guests. It's not a perfect system but for the most part only unique visits to previously unseen data count.

                    Now I will go get rank and uploading back on track. It should be pretty quick, I have my system established pretty solid so, this is just changing some key code here and there, while leaving most of everything else alone.

                    I have some more features that I made the SQL for but I never plugged it into any of the pages so, I will plug that stuff in too. That will put me basically where I was before I switched to prepared statements. When I fully catch up, I intend to go over all of the code, polish it and then move on.

                    This will basically mean going back to the flash work and getting a video player and slideshow app working. That's the starter kit.
                    http://www.nextgenquake.com

                    Comment


                    • #11
                      Hi, long-month-no-see. I just stopped in to throw an update here.

                      I have worked practically non-stop and sacrificed far too much sleep working on my project. There was a time a few weeks ago where I decided to sit down and really, really think about what I'm trying to build. It was a very smart thing to do.

                      I had one very important realization. I was not building a content management system, I was building the results of one. I understand that my above statement is a contradiction, due to the fact that you have to build some kind of CMS in order to get the results. The bottom line is, my back-end was being built to accommodate my front end and that is absolutely backwards. I was building ways to "take out" before I even had a way to "put in".

                      This all got me thinking, what do I really know about databases and SQL. Certainly I know how to create a database and tables as well as select, insert, update, delete, etc those tables/database, but how much is that really, when held in contrast to what is possible? I came to the conclusion that I know nothing about SQL and databases. I came to that conclusion without reading a single thing. It was "obvious" to me that for SQL and databases to be used for the most powerful websites known to man, I obviously was skipping a lot.

                      I went down to the most absolute basics (in my view) - table structure. Up til now my table structure was very "phpbb3". This is because I did the same thing to phpbb3 that I did to QC. I ripped it apart class for class and basically taught myself PHP/SQL based on the examples in the PHPBB3 source.

                      Whereas there is nothing necessarily wrong with that. I felt like the PHPBB3 database is a bit redundant. That's the keyword here "redundant". This redundancy led me to consider a lot of things. I went back to my database, which was equally redundant (although by no means identical). It would actually be more correct to say that I went to my database install script. The script is nothing more than every single line of SQL wrapped in a PHP connection/execution script. This allowed me to see every redundant spot in my code. When I say redundant let's consider this:

                      Code:
                      table_text_content
                      {
                      	id:
                      	name:
                      	title:
                      	description:
                      	content:
                      	keywords:
                      	owner_id:
                      }
                      table_media_content
                      {
                      	id:
                      	name:
                      	title:
                      	description:
                      	path:
                      	size:
                      	keywords:
                      	owner_id:
                      
                      }
                      The above structure is just something I typed out real quick for this example. In the case of objects prefixed with "table_" it's just to illustrate that I am referring to such. The inner names are the columns for that table. For example purposes, you will notice that the only difference between these 2 tables is, (content vs size/path). Aside from that we are using identical columns.

                      I began to write a new install script. This time I gathered every possible column SQL into an array (lets call it col_grp). Literally, an associative array of every possible column for the entire database. I then created more arrays that represented the common groups of columns that appear in the original code. So for instance, if (id, name, date) columns were primarily a recurring group - I would make an array that holds the association to (id, name and date) from my col_grp array (let's call this group basic_grp). I continued this until I had all the necessary groups defined.

                      Now, whereas I'm putting this all in code, what I'm really doing is writing a shorthand schematic that I can read. It just so happens that the shorthand is also real code. I say this because some of the more programming savvy of you, may think I am getting to a point where I feed these groups through a loop and do little more than recreate the exact same database I already had. That is not where I am going with this. At this point no "code" has been written, it's all "notes".

                      I stared at my groups for a very long time. There was some missing data due to things that don't really fall in more than one group. I wasn't really sure how to handle that data. I finally decided that the way to go was, to start removing all repetition from my first model but, keep the same functionality, while changing the model in every way. This is when I "invented" the node system. I'm sure I didn't really invent it, but I did create it with no influence or knowledge of it's pre-existence.

                      The node system relies heavily on foreign keys and orchestrating them is a bit of a challenge sometimes cause the node system also relies on a lot of ambiguity. My current model uses a table named node that has the ultimate group of column occurrences. This is actually about 3 smaller groups but they occur together very often so, I decided that they are the "core" columns for any given thing. Since these columns need to be associated with themself, quite often, I had to create a sort of loop (or maybe a chain)

                      example
                      Code:
                      node
                      {
                      	name: parent_01
                      	type: category
                      }
                      link:
                      {
                      	parent_name: parent_01
                      	child_name: child_01
                      }
                      node
                      {
                      	name: child_01
                      	type: post
                      }
                      There is more to the node table than just 2 columns but, the above is simply to illustrate how a node is tied to a link that is tied to a node. Actually many links could be tied to a parent node, each returning a different child node. The link table holds foreign keys which have both parent/child-name tied to name in node. This means if ex (parent) node is deleted the link will auto delete but (child) node remains. In the cas of a category/post that means I have to go manually delete all child nodes, however in most cases playlists, slideshows, file groups, etc I do not want the child to be auto removed. The child may be a member of some other playlist, slideshow, etc. That being said, the "manual" deletion of posts when a category is deleted, is a small side-effect to having the proper functionality for the most common occurrences.

                      I have figured out how to use this node system to create every possible thing I have considered building into my project. In essence it's like a big virtual table. Depending on the types that are returned, other "node-like" tables are joined to create a "custom" row of return data. The link serves as a decoupling of one node to the next as either node can be deleted and it's link will follow, but the node on the other end of the link is left untouched.

                      My overall database went from 19 tables to 7. I also accomplished something else in this method. The interaction SQL is small and re-usable. The SQL to get a category and posts is identical to getting an inbox and private messages, the only difference is "type". That is the ONLY var that changes. So, by making one thing, I set the stage for every relevant thing. Really, even a playlist is nothing more than a category and its members are essentially "posts" (except it's not text). So you see, the SQL just keeps getting reused with nothing more than a word to change (the one after "type").

                      Another thing I did but didn't realize til after I did it was, by creating my col_group array of every possible column that will be used in my SQL, and then creating all groups from that array, there is no data mismatch in my foreign keys. id of one table is a foreign key of id in another table, both tables got the id syntax from the exact same place. This means I can't fuck up. If I change the parameters for id in it's one place, it gets changed equally everywhere it is used.

                      I'm aware it's common practice to prefix columns, but I don't think this is necessary. I prefix my database and tables, if a hacker got past that SELECT * will tell them everything else regardless of what I name the columns.

                      Then there is my final thing. I decided to spend a whole lot of time soaking up as much SQL as I could. I wanted to REALLY know SQL. In my reading I found NODEGROUP in the docs. According to the docs it doesn't actually exist yet, but it is a placeholder for future functionality. The docs don't go into what it will actually do so, I have to make an educated guess.

                      NODEGROUP will serve as an id number that can be shared among multiple tables in order to accomplish the exact same thing I am already building from the php direction. That's my guess. To me it was a sign. I mean, I could have named my system and tables anything but I chose "node" - then randomly in the mySQL docs is a future variable that implies exactly what I am already doing. However, I do not intend to wait for them to implement it to get the show on the road.

                      ...off to stored procedures and triggers

                      edit: below is a semi-unfinished schematic of how private conversations will be linked. In the cases where I separated values with | it is to imply that more than one row can/will be returned for that table. The can/will part depends on what p[art of the schematic you are referring to. The way I nested objects is not to imply that those objects are a member of the other, it is to illustrate how certain things happen in a group.
                      Code:
                      user { id:5001, name:"user_01" rest... }
                      user { id:5002, name:"user_02" rest... }
                      user { id:5003, name:"user_03" rest... }
                      user { id:5004, name:"user_04" rest... }
                      
                      node
                      {
                      	id:		      7001     | 7002    | 7003     | 7004
                      	name: 		mb_ & user_01 | user_02 | user_03 | user_04
                      	type:		mailbox
                      	title:		"{USER}'s Mailbox"
                      	description: 	"Welcome to your message center"
                      	private:	1
                      	owner_id:	5001							//message senders id
                      	
                      	link									//deletion removes access to the entire conversation for this user
                      	{	id:		       | 1001    | 1002    | 1003    | 1004
                      		//order:	not_used
                      		parent_name: 	mb_ & | user_01 | user_02 | user_03 | user_04
                      		child_name:	convo_01
                      		type:		private_thread
                      	}
                      }	
                      
                      node
                      {
                      	id:		7005
                      	name: 		convo_01
                      	type:		private_thread
                      	title:		"{MESSAGE_TITLE}"
                      	description: 	"{MESSAGE_EXCERPT}"				//200 chars
                      	private:	1
                      	owner_id:	0							//owners can delete, this is a shared "box". Make the owner an impossible number or the site admin
                      	
                      	content
                      	{
                      		id:		10000
                      		parent_name:	convo_01
                      		text:		"{MESSAGE}"
                      		//keywords: 	not used
                      	}
                      	
                      	link
                      	{	id:		1009    | 1010    | 1011    | 1012
                      		//order:	not_used
                      		type:		reply
                      		parent_name: 	convo_01
                      		child_name:	reply_01 | reply_02 | reply_03 | reply_04
                      		
                      		node
                      		{
                      			id:		7006      | 7007      | 7008      | 7009
                      			name: 	        reply_01 | reply_02 | reply_03 | reply_04
                      			type:		reply
                      			title:		"{REPLY_TITLE}"
                      			description: 	"{REPLY_MESSAGE_EXCERPT}"
                      			private:	1
                      			owner_id:	5001      | 5002       | 5003      | 5004		//message senders id
                      			
                      			content
                      			{
                      				id:            10001    | 10002    | 10003     | 10004
                      				parent_name:   reply_01 | reply_02 | reply_03 | reply_04
                      				text:		"{MESSAGE}"
                      				//keywords: 	not used
                      			}
                      		}
                      	}
                      }
                      Last edited by MadGypsy; 01-14-2014, 02:33 PM.
                      http://www.nextgenquake.com

                      Comment


                      • #12
                        mini-update

                        Earlier I said I don't prefix columns and I gave some "lack of security" reason for this. Well, I finally got to the part where I can start testing my database and I had a big problem. When I joined rows variables from one table were overwriting the identically named ones from another table in the results array (lol). It dawned on me why table columns are generally prefixed with the table name... to avoid "conflicts".

                        It's cool though. I was able to fix that in like 1 second. My install script is an array of common syntax with groups pulled from that, then those groups combined into "super-groups", finally being fed through a loop and parsed out to the final SQL statement. This means there is exactly one spot to alter in order to prepend columns with table names (in the loop that parses everything).

                        Anyway, I have my database fully installed and I have all these schematics written (similar to the one in my last post), so now I have to go apply those schematics to some actual code. I also basically need to do the same thing I did with the install SQL to the interaction SQL. Many of the interactions with the database will be common groups of queries that only need a sprinkling of dynamicness. Now that I have prepended columns with table names, it does extend the amount of SQL I will have to write but my structure is still very compact so I don't expect it to be a nominal expansion of code.


                        also MISTAKE: I said I went from 19 tables to 7. That was incorrect. I went from 19 tables to 9. However (as a recap) understand that my 9 current tables are actually more powerful and versatile than all 19 of the old ones combined. I could (ex) add 19 more tables to the old structure and probably pull off all 19 of those extra tables with practically the same 9 tables I already have.
                        Last edited by MadGypsy; 01-14-2014, 09:16 PM.
                        http://www.nextgenquake.com

                        Comment


                        • #13
                          IDEA: Due to my node system certain things need to be handled differently than is the norm. One of these things is PM's. My PM box cannot work like a standard one because of the chain that needs to created for it to even be possible. My system focuses on working multiple users to the same instance of data. This means that no user can have the ability to delete that data. If a user is capable of deleting the data it would also serve to delete it from every recipients inbox, since everyone is being directed to the ONLY copy of the message.

                          This means private messages become private conversations. Where a conversation link is connected to the users mailbox node. That link leads to the solo copy of the entire conversation thread (RE. A user deletes "PM's" by "leaving a conversation". At which point they just delete their copy of the link to the conversation.

                          This got me thinking about what if a user replies to a conversation where any/all recipients have left? Surely there would have to be a system that keeps track of participants. I figured one out and it is simple. A link is made between the conversation and the user_id, tied to the conversation node back to the user. A user has 2 options. Leave the conversation (delete their link) or leave a conversation permanently (delete their link and the link back). If the former is selected, when a user replies to the conversation, a new link will be installed in all recipient mailbox nodes which have deleted their initial link. In other words, it puts it back. If the latter, you officially have left the conversation and it will never re-appear.

                          From the conversation end if there is only one link-back left in the conversation node, that user is notified that everyone left the conversation, is given the option to save the conversation as XML and the entire conversation is deleted from the database. Actually the entire conversation would be deleted from the database before the user even got the notification. The xml version can be pre-made and stored for download indefinitely.

                          All of this gave me another idea where all conversations have a long pre-set expiration date (90 days?) and no matter what, conversations expire in full, are dumped to xml and dropped from the database. Which gave me the final idea to allow users to set their own expiration date that is as short as 1 day and as long as 90. Kinda like some Inspector Gadget stuff... this message will self destruct in 5 seconds. (lol) I think in this day and age, completely vanishing messages could be handy, especially private ones.
                          http://www.nextgenquake.com

                          Comment


                          • #14
                            Thanks for the update, was curious as to how things were going.
                            twitch
                            wew lad

                            Comment


                            • #15
                              Not sure this is of interest but might be



                              Valve Replaces The Steam Machine Controller’s Touchscreen for Physical Buttons | Unigamesity

                              Comment

                              Working...
                              X