-
Posts
374 -
Joined
-
Last visited
-
Days Won
8
Everything posted by clsource
-
Ok so we should start the poll with all the candidates! :V
-
So if there are no more suggestions I think we should begin the poll to define the first nickname for Processwire!. Nickname proposals will be received until Sunday 26-10-2014 GMT - 4 Monday 27 we should start the poll until December, shall we?
-
Hello, Today a client told me he want a site similar to this http://thecoffeekit.com/ Yes, my first option is PW of course. but I'm wondering what tools can be used. For those who don't speak spanish the site is a subscription based service that brings you coffee to your home or office. so they have this page http://thecoffeekit.com/orders/802BA39F/pricing?plan=PLAN-500G when you select how much coffee you want, get the price and then select your product. anyone knows a jquery plugin, or share some suggestions or thoughs? I would really appreciate it thanks
-
sounds fun! any sugestions?
-
So far we got these nicknames Tesla Newton Einstein Gehry Bancroft Goldfinger Smithson Pasmore Luder Chamberlin Powell Bon Blackbeard Calico Jack Henry Morgan Sir Francis Drake
-
Wow! Just made my day
-
Hahaha so we should have a showdown scientists vs architects vs pirates! the most voted name will be honored to be the nickname of the current PW 2.5!
-
This is a very good newsletter I think https://serversforhackers.com/
-
Hello, I'm Just wondering if the Newsletter system is made in Processwire or they use other solutions. like mailchimp. I think should be a fun project making a newsletter system, that powers the processwire newsletter. Using systems like http://mandrill.com/ making a newsletter app becomes more straightfoward I think.
-
So, should we made a Poll? Why not we take names from architects and inventors and choose by a democratic vote? xdd some Inventors that comes to my mind are: Nikola Tesla ~> Processwire 2.5 'Tesla' Isaac Newton ~> Processwire 2.5 'Newton' Albert Einstein ~> Processwire 2.5 'Einstein' ?? I do not know many architects though
-
Hello, I think it would be fun to nickname the Processwire versions like the mayor softwares (Wordpress, Ubuntu, Mac, etc). So I propose that versions should be nicknamed after scientists/inventors or cool people that make experiments because Processwire "ancestor" Dictator CMS was named after the Thomas Alba Edision's Dictator Machine. Also, nicknames could come from beer, wine or fantasy characters like Bilbo Baggins or Gandalf?. What do you think?
-
Well I Created a Simple Module that outputs the metatag. Why a Module?, because it's more easy to modify the meta tag and additional info in the long run, and standarizes the tags I think. <?php /** * ProcessWire Meta Tag * * Returns this meta tag * <meta name="generator" content="Processwire.com" /> * * Usage: * * In you header/ template/ _main , add this * * * $pw_meta = $modules->get("ProcessWireMetaTag")->get(); * * <head> * <?php echo $pw_meta ?> * </head> * * By Camilo Castro @camcasc (ClSource) */ class ProcessWireMetaTag extends WireData implements Module { /** * getModuleInfo is a module required by all modules to tell ProcessWire about them * * @return array * */ public static function getModuleInfo() { return array( // The module'ss title, typically a little more descriptive than the class name 'title' => 'Processwire meta tag', // version: major, minor, revision, i.e. 100 = 1.0.0 'version' => 100, 'author' => 'clsource', // summary is brief description of what this module is 'summary' => 'A simple meta tag for saying that you use Processwire and spread the word .', // Optional URL to more information about the module 'href' => 'http://www.processwire.com', // singular=true: indicates that only one instance of the module is allowed. // This is usually what you want for modules that attach hooks. 'singular' => true, // autoload=true: indicates the module should be started with ProcessWire. // This is necessary for any modules that attach runtime hooks, otherwise those // hooks won't get attached unless some other code calls the module on it's own. // Note that autoload modules are almost always also 'singular' (seen above). 'autoload' => true, // Optional font-awesome icon name, minus the 'fa-' part 'icon' => 'smile-o', ); } public function __construct() { // Set meta property $this->meta = '<meta name="generator" content="Processwire.com" />'; } /** * Initialize the module * * ProcessWire calls this when the module is loaded. For 'autoload' modules, this will be called * when ProcessWire's API is ready. As a result, this is a good place to attach hooks. * */ public function init() { // Nothing to init } // Returns the meta tag public function get() { return $this->meta; } }
-
So I have to use another computer for development and have to do some additional steps when you are using an existing repo. First You have to generate id_rsa.pub and add them to the authorized_keys in the hosting. (copy and paste the entire new rsa below the old one) Example if you have 2 RSA ssh-rsa A521312312123xg7/E6JK1Noo7t4Oqh5AQVSdCQqlXVO0IpMEHK7zefsNj1IBauAOtfK123312inqHV3avzIu2I/dzHWSYXI5pGkdnYkakkckasN1ovQ7FkQ1gUg6OCgKgEPzQyC5/nSmK+zBdOvbYNtY/g99234bt7+VDpoC9dqK9uOcfmdpVYqwertyqTll9JVdf4KESH1ssLYYCHa6WH0yQfDE2rSR/5Edu0YLLFN email@email.com ssh-rsa ch123312AXx6/MFa7cDtoznUF6ViirJhsL6KOSNKmkt8jjdjjjjj12b5ND8DouaaMtwaQ8j/5554ffaasdfbkWlfv123UwbDLxwCwKGLi++++JGI7aotsOQcL/ea7CS2kov5yS4PsGoSwnRM0D5lK3psGn/pE0V8Pgmg5AvfxfvTHml email@email.com In your local machine go to .ssh/config and add your hosting info HostName hosting.com Port 2222 PreferredAuthentications publickey now create a new directory, go inside and create a new git repo $ mkdir my_project $ cd my_project $ git init Then add the remote host $ git remote add hosting user@hosting.com:www/my_project Pull the repo $ git pull hosting master Make some changes and push them to the hosting $ git add . $ git commit -m "Some changes" $ git push --set-upstream hosting master Now you can work using simple $ git push
-
Yes that wil be very useful. How you handle multi threading? Lazy Cron Module creates a dummy lock file I think. that if exists does not execute the cron job.
-
Hello, I wonder if you can have some sort of transactions using PW API. in order to rollback any changes made to a previous state if something went wrong. For example if you have a shopping cart. a product that only have 1 item left. two people that want that product at the same time. One gets the product, the other gets an error. You can have something similar using many 'if '. But something similar to this, I think could be cleaner. Thanks
-
Never been there before. I think you should try some good homebrewed beers
-
I think a better comparison will be people positive reviews vs negative reviews. The more positive and constructive reviews of a software inside a year could lead to a better winner election. Maybe something like this: Most Positive Reviews Most Negative Reviews Editor Choice People Choice.
-
I think you can achieve a similar behaviour using pages and some module that merges the changes. Like you have page A on production. You need to change A but push the changes later. Create a Duplicate unpublished page A, commit changes and merge A with the duplicate. I think some module could do that.
-
Hello, So I'm working on a PW project in a shared hosting like Hostgator. For this to work you need ssh access, and of course git. I always have problems working with FTP, I feel my productivity decreases when using them, also you have no control over changes that are made. So a single file deletion could cause a big catastrophe. The first thing you have to do is cloning the PW repo, and checkout to dev branch Here we clone the repo, use the dev branch. Delete the entire PW git directory and initialize a new one $ git clone https://github.com/ryancramerdesign/ProcessWire/ $ cd ProcessWire $ git checkout dev $ rm -rf .git $ rm .gitignore $ git init $ git add . $ git commit -m "Initial Commit" Note: The file .gitignore from the dev branch have some files that you want to be commited, like /sites. I recommend deleting that file and create a new one. Ok, now we need to configure our remote repo inside the shared hosting. You need to login using a terminal. Linux and Mac have ssh already installed, if you are in Windows you can use Putty. ssh username@domain.com -p 2222 ... Enter your password: ********* Now we need to authorize our computer in the hosting, so we can push the commits. We need the contents of ~/.ssh/id_rsa.pub located our computer. A more complete guide for generating such keys is available here. Then we will copy the contents to ~/.ssh/authorized_keys. create the authorized_keys in the hosting if not exists using touch ~/.ssh/authorized_keys The next step is creating a new repo and configure some hooks in our server. $ mkdir www/processwire $ cd www/processwire $ git init $ git config receive.denyCurrentBranch ignore $ cd .git $ cd hooks $ touch post-receive The contents of post-receive hook should be. (this is a ruby script, but could be any language available on the server) #!/usr/bin/env ruby # post-receive # 1. Read STDIN (Format: "from_commit to_commit branch_name") from, to, branch = ARGF.read.split " " # 2. Only deploy if master branch was pushed if (branch =~ /master$/) == nil puts "Received branch #{branch}, not deploying." exit end # 3. Copy files to deploy directory deploy_to_dir = File.expand_path('../') `GIT_WORK_TREE="#{deploy_to_dir}" git checkout -f master` puts "DEPLOY: master(#{to}) copied to '#{deploy_to_dir}'" # 4.TODO: Deployment Tasks # i.e.: Run Puppet Apply, Restart Daemons, etc Now we make it executable using chmod $ chmod +x post-receive With all that done, we should enable a passwordless login so we can push without a password prompt on every push. In our local machine look for this file ~/.ssh/config And add this text (Change your-domain.com and port as needed) Host your-domain.com Port 2222 PreferredAuthentications publickey Now we should go to our project directory and add the remote host with $ git remote add hosting user@domain.com:www/processwire $ git push --set-upstream hosting master This should do the trick for commiting changes and upload files without ftp. Now we must install Processwire and then pull the changes. Go to your domain and start PW setup. once you are ready installing processwire, you need to pull changes that PW installer made. Login to your hosting via ssh and commit the changes that installer made. $ ssh user@domain.com $ cd www/processwire $ git rm $(git ls-files --deleted) $ git add . -f $ git commit -m "Initial PW Setup" When that is ready go back to your local machine and pull the repo. $ cd Processwire $ git fetch $ git reset --hard hosting/master Now we are finally ready to start working with PW in shared hosts or other machines that have ssh enabled. simply makes changes like $ touch site/templates/welcome.php $ git add . $ git commit -m "Added welcome.php" $ git push Now if you have some problems you can zip the setup using $ git tag -a v0.0.1 -m "Initial PW Setup" $ git archive --format=zip --output=pw.zip v0.0.1 And download the file and work from there Thats all References: http://www.arlocarreon.com/blog/git/push-git-repo-into-shared-hosting-account-like-hostgator/ http://ahmadassaf.com/blog/miscellaneous/how-to-use-git-to-host-and-push-projects-on-shared-hosting-services/ http://motorscript.com/setting-up-a-remote-git-repo-on-shared-server-like-hostgator/ http://krisjordan.com/essays/setting-up-push-to-deploy-with-git http://git-scm.com/book/en/Customizing-Git-Git-Hooks
-
@adrian Thanks, that was helpful.
-
Hello, I think that an option inside templates that could limit the number of childrens that a page could have, maybe is useful in certains conditions. it´s that possible or I have to rely on hooks? thanks.
-
@SiNNut Thanks for pointing that out. Where can I find more info about field contexts? thanks