Jump to content

Adam

Moderators
  • Posts

    5,717
  • Joined

  • Last visited

  • Days Won

    6

Posts posted by Adam

  1. Gulp runs in the node environment, so you can just use node's module loader to import the data within arrayfile, then export it as an array for your Gulp script to import.

     

    arrayfile.js:

    module.exports = {
      somefile: require('./somefile'),
      someotherfile: require('./someotherfile')
    };
    
    gulpfile.js:

    var data = require('./arrayfile');
    console.log(data.somefile);
    console.log(data.someotherfile);
    
    You could export an array from arrayfile.js (the name of which obviously doesn't make much sense when you export an object), however having named properties to access a different file's data feels a little more elegant, and is better for readability.
  2. While I wouldn't agree that it looks totally different in every browser, I wouldn't say that I like the look of it. The colours don't work together, the images look bad quality, everything just seems unorganised. If you're hoping to get work from this website I would seriously invest a bit of time into learning a bit about design, or just go with something simple.

  3. By "moved to another table" I presume you just mean normalised? It really depends on what kind of functionality you're going to provide. If it's just a basic send mail wrapper then you probably don't need to worry, given it will be sent in the CC header in exactly that format.

     

    If however you want to provide a more advanced address book, and/or provide some kind of filtering of sent mails, then I would probably normalise the data. Normalising the data complicates the code of course, so unless you have the need to do it I wouldn't bother -- KISS.

  4. After saving the data in the database, you need to retrieve the last inserted ID, and then redirect the user to another URL with that ID passed as some kind of parameter.

     

    This other URL will then run a script that fetches the information back from the database using the ID passed in the URL, and then display it in some kind of template.

     

    Individually they're all relatively simple things to do; just google them separately, and put the pieces together.

  5. Generally the only difference is the encryption level, liability insurance and whether you get the full green bar. Seeing the green padlock is apparently important now to users, as they're made more aware of web insecurities, and of course Google now rank you higher for having an SSL cert. SSL should not be a worrying factor of speed these days. If someone is having issues then it's more than likely the server at fault, not a direct result of having an SSL certificate.

    Bottom line is definitely have an SSL cert if you're selling stuff, but realistically I wouldn't worry about paying out of the arse for anything advanced. Run of the mill will do until you enter the major bucks revenue wise.

  6. Im also looking for a framework,  but Laravel seems too fast moving for me.  I want something with a relatively long lifecycle per release.  I don't have time to relearn stuff every couple of months.

     

    Any suggestions.  I need really lightweight,  shallow learning curve,  keeps out of the way,  but comes with a nice feature set that I can use if I want to.  I find out of the box Auth never does what I want ect so don't want to be forced to use something.

    Can't believe you registered just to post that. CodeIgniter sounds perfect for you.

  7. My question is, how does this compare to a node.js and socket.io server with a MYSQL plugin, etc? seems like that route would actually be more intensive?

    I'm not sure how you came to this conclusion; from every benchmark I've ever seen, node.js beats PHP in comparable situations. Especially in this kind of scenario. If you've performed any kind of benchmarking (results?) and have seen PHP seem favourable, you should be providing specifics.

     

    Love it because I don't know javascript as well as I do PHP. (Absolutely hated learning socket.io and their style of javascript, just gave up on it).

    'Their style' is just the same as any other node application/library. It takes time to adapt to writing the majority of your code asynchronously, in order to get the best out of node. If you've been writing it in a way that goes against its nature, it's not hard to imagine why you're not seeing the performance others are seeing.

  8. Can you show the actual output from the server when you try logging in with a password (-p argument)?

     

    From what you have posted it seems like password authentication isn't allowed, in which case you will need to add your public half of a key (see here for how to generate the key: https://help.github.com/articles/generating-ssh-keys/), but if you can't SSH to it, you can't add your key to the authorised keys file on the server. So do you have any other form of access? Who maintains the server?

  9. using composer it asks for php in my local files?

    I'm not entirely sure what you mean by this, hosting and running the PHP code locally? If so then you'll need to install a HTTP server (generally Apache), PHP itself, and most likely a database server (generally MySQL). You'll be able to find literally millions of tutorials on how to install each of these individually, or as an OS-specific package like MAMP or WAMP.

  10. I agree with KevinM1. In the near future there's only going to be 2, maybe 3 dominant frameworks; Symfony2, Laravel, and last and least Zend2. Laravel in all honesty is very good, but it lacks the maturity and widespread use that Symfony2 has managed to establish. Having said that, you get the feeling Laravel is going to be pretty big in the future.

     

    The next year or two of framework wars will be interesting as they push each other.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.