Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Leonid Mamchenkov:
PHP: Countries and currencies
Dec 04, 2018 @ 16:33:41

In a recent post to his site Leonid Mamchenkov has shared a few links to packages that provide country and currency lists and a new one he's discovered that does an even better job.

Many software projects deal with the lists of countries and currencies. Some of the most common tasks include country an currency dropdowns, country flags next to the IP, or pre-filling country codes in phone numbers.

All of that information is of course standardized and you often just need a library or two to provide and use it. And there are many of those. [...] Today, however, I came across a better option – antonioribeiro/countries, which is a collection of country and currency information for Laravel PHP framework. Laravel is not required though.

The package, easily installable via Composer, provides information for over 250 countries and 250 different currencies. There's also flags, maps, states, cities and more. Check out the repository for the full list of data it offers.

tagged: package currency country listing options

Link: http://mamchenkov.net/wordpress/2018/11/30/php-countries-and-currencies/

StackOverflow:
A Tale of Two Industries: How Programming Languages Differ Between Wealthy and Develo
Sep 01, 2017 @ 17:44:03

On the StackOverflow blog there's an interesting post that looks at the differences in programming languages between countries based on their current state, either a developing country or a wealthy one (or somewhere in between).

Here at Stack Overflow, we’re interested in using our data to share insights about the worldwide software development community. [...] This leads us to wonder how else programming technologies may differ between rich and poor countries, and how that affects our picture of the global software development industry. In this post, we’ll explore these differences, and show that’s it’s useful to segment the software development industry into high-income countries and the rest of the world.

All the analyses explored here were performed on 2017 so far (January-August), on the 250 tags that had the most traffic during that time.

They investigated some of the major programming languages and platforms (including PHP) and found some interesting negative and positive correlation results. The post then covers how they split the list of countries in two (wealthy vs developing) and show results of the technologies they use. They include graphs for each of the points they make and link over to their StackOverflow Insights site where you can gather statistics for evaluation of your own.

tagged: stackoverflow programming language country difference statistics

Link: https://stackoverflow.blog/2017/08/29/tale-two-industries-programming-languages-differ-wealthy-developing-countries/

Mathias Verraes:
Value Objects and User Interfaces
Nov 18, 2013 @ 17:35:07

Mathias Verraes has a new post today with a response to an email he received about some comments on a recent Elephant in the Room podcast about Value Object usage. The question asks about usage of Value Objects, specifically when it comes to things like country information.

There’s nothing intrinsically wrong with modeling countries as entities and storing them in the database. But in most cases, that overcomplicating things. Countries don’t change often. When a country’s name changes, it is in fact, for all practical purposes, a new country. If a country one day does not exist anymore, you can’t simply change all addresses, because possibly the country was split into two countries. Whenever you have this kind of friction, there’s usually some missing concept screaming to be discovered.

He talks some about the concepts around the "country" data and some of the functional concerns around it (duplicate checking, validation of existence, etc). He takes the concept and breaks it out into two different concepts - the actual Value Object of a single country and an "AvailableCountries" set (and "AvailableCountryRepository").

tagged: value object country example registry set

Link: http://verraes.net/2013/11/value-objects-and-user-interfaces/

Community News:
PHP: The Undiscovered Country (Event)
Aug 20, 2013 @ 14:10:25

At the end of this month (August 29th and 30th), there's a PHP event happening in San Francisco, CA that calls itself a "unique gathering of exceptional PHP developers from around the globe" - PHP: The Undiscovered Country. This two-day event includes speakers like:

  • Nate Abele
  • Graham Weldon
  • Garrett Woodworth
  • Dean Sofer

The sessions are covering things like the future of PHP application development, working with virtual teams, the HipHop VM and future-proofing your APIs. You can still pick up tickets for the event too. So far they've posted the Day 1 schedule to the site with more information (and other speakers) to come.

tagged: pud13 undiscovered country engineyard event conference

Link: http://phpundiscovered.com

Sherif Ramadan:
Web Analytics with PHP and Google Visualization: Made Simple
Dec 19, 2012 @ 18:38:47

in this new post to his site Sherif Ramadan shares a method for visualizing your website's visitor data with the help of the Google Visualization APIs and some geolocation.

The web is a place where everyone is in your backyard. This can be both a blessing and a curse. How do you know where your website traffic is coming from and how much of it there is? [...] How was traffic led to your website in the first place and why? How long do people stick around and what do they like the most about your site? These are all some of the many questions you can answer with web analytic software, but the real question is why would you want to answer these questions at all and what’s the best way to look at the answer?

[...] If we look at a heat map it’s easier to spot where the majority of our visitors and traffic are coming from, geographically. It also helps us understand that people visiting a virtual space can, and will, be physically located in different parts of the world.

He includes the steps to recreate a map like the one included in this page showing the current view statistics on his site. He uses a MySQL backend to store the GeoIP data and parses out the Apache "access_log" to get the IPs of the visiting users. He then runs these against the GeoIP data and passes this country data on to Google's visualization for handling. He also recommends using the tools offered by the Google Webmaster Tools to further enhance your introspection into your site's visitors.

tagged: google analytics geolocation analytics visualization country

Link:

PHPMaster.com:
Pagination with CodeIgniter
Jan 30, 2012 @ 18:15:22

On PHPMaster.com today there's a new tutorial showing you how to handle simple pagination in a popular PHP framework, CodeIgniter.

Pagination is particularly useful when you are coding an application that interfaces with a database. A large dataset might have hundreds of possible results for one query, and pagination creates a much nicer user experience. In this tutorial, I’ll use CodeIgniter’s pagination library to show you how you can create a paginated list of results from a MySQL database. Along the way, you’ll also see how to fix a problem with the pagination links that the library might produce.

He starts on the backend, creating a model to work with Country information and includes a "fetch_countries" method to grab the limited/paged list. Next up is the controller with an "example1" method that looks to the URL to see what page it should be on. The view is simple enough - just outputting the results back without worrying about how many to show.

tagged: codeigniter framework tutorial pagination mvc country

Link:

Ilia Alshanetsky's Blog:
Domain Location Statistics
Dec 20, 2010 @ 18:15:18

Ilia Alshanetsky has started to gather more and more information about PHP usage on the web as a whole (that was started here) and has been extended with some additional statistics he's done on the location of the domains he's collected.

The first step of the process has been resolving all of these domains, which is now complete. The next step is fetching the server information, which began, but will take some time to finish. However, even from the domain revolving data there is a lot of useful data to be gleamed, which is what I am now publishing. My first focus was on the world-wide distribution on these TLDs, which at least for me held a few surprises.

He includes a few graphs of the results he's found showing things like:

  • The US has the most domains hosted followed with less than half by Germany
  • The overwhelming majority of the PHP domains are in the .com area
  • In the US, the state with the highest number of PHP-powered domains was Arizona with Clifornia coming in second

If you'd like something more interactive, he's also come up with a clickable world map of the results for you to click around on.

tagged: domain statistics country state tld

Link:

Init Marketing:
Calendar of Open Source, IT, Industry-specific Events
Mar 06, 2009 @ 17:13:06

If you're looking for Open Source events to attend in your area (or just about anywhere around the world), check out this calendar as provided by Init Marketing with a great listing of happenings in over fifteen countries around the world.

Below calendar contains world-wide conferences and trade fairs related to Free and Open Source Software, IT and specific industries. It also shows events where you can meet with InitMarketing.

Countries included in the list are Germany, the US, Japan, Italy, Australia, China and many more. If you have an event that's not on the list and you'd like to see added, leave them a comment on that page and they'll get in contact with you.

tagged: opensource it event calendar country

Link:

DevShed:
Using Code Igniter to Build an IP-to-Country Mapping Application
Feb 25, 2009 @ 13:57:11

DevShed finished off their tutorial series looking at mapping IPs to countries in a CodeIgniter application with this new article completing the application to provide a correct products list based on their location.

In this final chapter of the series, I'll be discussing how to build multi-lingual web pages by combining the functionality brought by the "iptocountry" MySQL table that you learned in previous tutorials and the power of the Code Igniter PHP framework.

Their database tables sort the prodcuts out with the three character country code they're associated with. The IP-to-country tables then help with the translation between the visitor's IP address and which products should be shown.

tagged: country ip mapping products codeigniter framework

Link:

DevShed:
Building Sample Programs for an IP-to-country Mapping Application
Feb 11, 2009 @ 14:44:29

DevShed has posted the second part of their series looking at an IP-to-Country mapping application, this time with a focus on building some simple applications to use the data inside.

Building a web site that will be seated on a multi-lingual platform often requires developing an IP-to-country application that permits you to map users' IP addresses to their corresponding countries. [...] This database contains over 82,0000 records and allows you to map more than 3,200,000 IP addresses to their respective countries. This can be really handy for developing different IP-to-country applications with minor efforts.

The review the previous article on making the database and move ahead to create a script that selects - based off the IP range - the country that address could be from.

tagged: ip translate country mapping application program tutorial

Link:


Trending Topics: