-
Trouble Installing NPM Modules... (NodeJS)
To close this thread off... While I appreciate the amount of work that's gone into the whole Mimosa package, it quite simply doesn't gel with my workflow. In researching the implementation of another of my projects, I found Partial.js to be an almost almost perfect starting point. While it's not even that same type of system as Mimosa, I prefer starting off with a clean slate and adding only the functionality I want / need in my app.
-
Trouble Installing NPM Modules... (NodeJS)
Heh, just my luck.. Small discovery, watching my project folder while Bower installs something, it appears to download a Git repo, extract the files it needs, then clear the temporary download folder... While this still doesn't fix my problem, it is still somewhat applicable to my question; I can't see a way to install anything with this that isn't listed in the Bower list of available downloads.
-
Trouble Installing NPM Modules... (NodeJS)
Unfortunately I don't see much NodeJS activity in these parts, so I'm taking a chance here.. But I'd like to avoid adding yet another forum subscription to my already long list, so I'm hoping someone here with a better understanding of JavaScript can point me in the right direction? For reference, my current code for this project can be found here, to which I've just pushed my latest changes for clarity. I'm rather new to NodeJS, not quite so new to the concept of AMD style JavaScript, but I can't figure out what's going on here. In case you're not familiar with the boilerplate I used, the generated website's index file is in the `/views` folder, and the rest of the published web app is built inside the `/assets/javascripts/app/` folder[1]. So, with a standard NodeJS setup, the command... npm install <module> ...would install the chosen module to the `/node_modules` folder, and using... require("<module>"); ...inside a Node app module file would know where to load it from thanks to it's own environment. With my current setup (boilerplate source), npm installs the module as expected, but I can't load it from within my app folder [1]. In case it makes any difference, in this particular case I'm trying to install nano. I've checked both the Mimosa documentation in case this is a framework-related issue, but I see no mention of how to load standard NodeJS modules (only `mimosa-<module>` is available). Then I checked the Bower docs in case it's to do with the copy/install/download system, but that left me even more confused. If I try change any of the module dependencies set in `bower.json`, it ends up pulling the original boilerplate into my project again, overwriting my initial files and therefore the app itself. Any bright ideas? I'm itching to get on with this project, but I can't until I work a way around this.
-
Server Asset Delivery Optimisation - Need Some Advice...
Fair points, and very valid as well.. I thought I'd mentioned in my OP that the majority of what I'm doing with this VPS is literally just to have my own little playground and to gain experience. I am already quite familiar with combining and minifying stylesheets and script files served from within the web app's folder, I guess part of this was just to see if I could... The Nginx idea is an interesting one, I've looked at it before, but I was still playing with PHP more than anything else at that stage, so I decided to stick with Apache. It honestly didn't even cross my mind for this particular case until you mentioned it though.. It should at the very least be an interesting experiment though, so I'll probably play around with that. The majority of points listed on that Yahoo page you linked to actually just come down to plain logic, however they are explained very nicely in that particular page. So, I think before I go too much further with any of this, I must first sit and read through it, brush up on the core ideas again, and then start making plans after that. Thanks for the tips..
-
Server Asset Delivery Optimisation - Need Some Advice...
While driving to work this morning, I had an idea for how I could do this.. The basic idea is to have a simple page on my assets sub-domain with functions that accept an array of file names, then process those and return the end result, rather than trying to catch all URLs and then process them. I'll play around with this tonight when I get home and see how it turns out.
-
Server Asset Delivery Optimisation - Need Some Advice...
I've been playing around with my VPS the last couple days, I decided to split my web project into sub-domains instead of relying on sub-folders.. But I'm not entirely sure how to go about implementing my latest idea. I would prefer to be left to actually code it myself, but I need some help with working out what I need to make the code do.... So, on with the topic at hand.. I've set up an 'assets' sub-domain, which I'm planning to use for serving assets that are common to my other projects (Twitter Bootstrap, jQuery libraries, branding images, etc). However, instead of simply serving the requested file or files, I'd like to see if I can get my 'assets' sub-domain to combine and minify the requested files. My current idea involves using a PHP-based server-side app that only runs when an asset is requested; at which point it will process the requested files (for example: combine, minify, gzip, etc..) and serve them back to the browser. Perhaps it could even cache the processed files and serve them directly if the source files haven't been changed... But, for all my Googling skills, all I could find was information on how to implement things like this in a self-contained app running off one domain (and more WordPress-related results than I care to count). So I'm not entirely sure how to set up something like this... Anyone have any suggestions for this? I suspect all I need is a starting point for the logic, after that the rest of it should theoretically fall into place quite easily.
-
Abusing the !important Rule...
@BlueDreamer, I'd hazard a guess and say it's more likely to be from simple misuse rather than laziness... Comparing a well planned stylesheet to one with what feels like each rule in multiple places, each overriding another while hugging an !important clause; the former is actually less work anyway. I have found uses for it though, but I don't think I've ever needed more than one or two !important rules at most in a full site. Even then, I think those cases were simply to override unwanted CSS borders or rounded corners. @WebTam, this template was built on top of the Gantry framework, but I'm not sure where exactly all these rule importance modifiers came from in the first place... I don't use pre-made themes myself either, but I have a friend who's brilliant at the designing sign and learning the coding side, but she gets stuck with it sometimes and sends some work my way (such as in this case). @Alluziion, talking of external stylesheets and !important, another time it may come in handy is when the order in which stylesheets load isn't quite as it should be. But even in that situation, it's still very hacky. I'd rather fix the load order of the stylesheets anyway. I just find it shocking how little pride and effort so many people put into the code they write..
-
Abusing the !important Rule...
So, this is a bit of a two-part post... On the one hand, this could serve as a "don't do this! ever!" sort of message, and also I think I might need to rant... Just a little bit. First things first, I've blurred the identifying comment at the top of the sheet (I do have some decency), but take note of a few things in this screenshot first: For those of you who don't know Sublime, the sidebar on the right is a thumbnail scrollbar that in this case is showing about three quarters of the document. All the little light blocks in that scrollbar are matches for the '!important' rule I have selected on line 16. This particular document is imported at the core of a collection of .less files in a "custom website template". Why do this? Seriously?? This makes it virtually impossible to create any sort of personalised website based on this theme, especially since it always includes these files. Please, I beg everyone who reads this.. Please put a bit more planning into your stylesheet layout and avoid abusing the !important rule? It's hell for us freelance coders to have to fix the template before we can start fixing the customer's site (which is what we should be doing).
-
Looking for Some DNS Advice
My apologies for double posting, can't edit the message I posted last night.. I just found a DNS health checking service at www.intodns.com, which amongst other things, told me: If I understand this correctly, this means I also need to have ns1 and ns2 set up as A records pointing to my VPS IP in my AfriHost DNS panel, since that's handling DNS for boxofgrief.co.za. Is that assumption correct? Edit: Yay! The A records worked. Happy dance time... Must admit most of this does still go a bit over my head, but considering it's just a hobby, it's already been a very educational ride so far.
-
Looking for Some DNS Advice
So... IS accepted my update request, and the change has now taken effect, but something seems to have gone quite badly awry now... If you try access gecco.org.za, Chrome gives me "Error 137 (net::ERR_NAME_RESOLUTION_FAILED): Unknown error." (FF and IE just fail to load the page). I was pretty sure I had everything ready to go, but apparently not. The DNS settings for my domain have the following records: The ns1 and ns2 records were already there, I didn't need to add them myself. I'm not sure what to try next. Any suggestions?
-
-
Looking for Some DNS Advice
Ah, ok cool. Looking at the DNS management in my AfriHost panel, it already has ns1.boxofgrief.co.za and ns2.boxofgrief.co.za with the correct IP... So that actually makes it really simple then. I'll put through my DNS update request for the gecco.org.za domain now quickly and see if they like it. Thanks Chris, you have an uncanny knack for making things sound so simple.
-
Looking for Some DNS Advice
Hi JaCEnt, I'm not sure if I can use AfriHost's name servers for this, they don't know anything about the gecco.org.za domain... When I log into my clientzone, I can only add/edit records for my personal domain (boxofgrief.co,za), I can't add other domains to the list. If my idea of running a name server on my box doesn't work out, I'll check on the possibility of managing the gecco.org.za DNS from my clientzone as well. What I would ultimately like (partly because I have a VPS with the required capabilities and partly because I'm a bit of a control freak), is have IS's records point to my own name server (perhaps using ns1.boxofgrief.co.za for example), so I can control DNS for gecco.org.za from there. Currently gecco.org.za is going to a friend's NS (ns1.crc.za.net, ns2.crc.za.net), from which point it's being directed to my VPS's IP address. He has immigrated though and is trying to shut down his server, so I need to get IS to direct requests to my server directly, instead of going through his first. Not sure if that clarifies my reasoning for this request? re:P.S. DOTT was an awesome game, I actually still play it now and then, but Purple has been my avatar of choice for more years than I care to remember.
-
Looking for Some DNS Advice
Before you read too far through this post, please note I am very new to the web server management scene, I'm not looking to build a run a website hosting business or anything like that, I'm simply trying to help a local NPO with a website. Good old charitable work and all that.. So, with that out of the way, here is what I currently have to work with... A private VPS with BlueVM (based in USA) with a single static IP address Two domain names registered (more details below) AfriHost handle my domain (boxofgrief), and with my DNS Management control panel in their clientzone I've directed the domain to my VPS, so I've got no issues there. The top level DNS record for the NPO's domain (gecco.org.za) is managed by Internet Solutions (let's just call them 'IS') here in South Africa. Although I don't have any sort of control panel access, it's easy enough to update that, all I need to do is send them an email with the new details (which they validate before updating). However, this is where I'm getting stuck. If I'm not mistaken, I should be able to use the root zone in BIND on my VPS to setup a small name server, add records for the NPO's domain, and then simply get IS to use the name server from my domain. Correct? Before I go requesting changes though, I just want to check that what I want to do can actually be done. If you can help me and need more info first, please let met know.. I'm running Webmin (with VirtualMin) on my server, but I do also have SSH access as well. Anyone feel like helping me out here?
-
Custom Fields in Joomla K2
Thanks for the detailed response, I'm still learning my way around Joomla's structure, but I do follow what you're saying.. Unfortunately I don't have time to look into this right now (I'm moving house this weekend), but once I've settled into my new place I'll tackle this again and see what comes of it. Hopefully I can do that early next week.
-
-
Custom Fields in Joomla K2
As the title suggests, I'm looking for a way to add a new field to articles created with K2 in Joomla. The site I'm working on is using Joomla 2.5.6, and a custom front end theme. If possible, I would like to add the new field (called 'subtitle') into the admin template directly below the default 'title' field. From there I can pull it into the front end template and display the title/subtitle in the various places they're used. Does anybody know offhand how I can accomplish this? Or perhaps have a handy link to a tutorial that covers this? Just for the record, I did find a post here that seems to cover what I need.. But I tried it just now and it didn't seem to work, not sure if I did something wrong or if it simply won't work for the latest versions of Joomla (post is dated April 2011).