Clone any static site by a simple Linux command WGET

by Yang Yang on November 8, 2019

Just use this and the WGET command will start crawling the target site and download certain levels of pages from the starting URL, including all its assets such as images or CSS files.

wget -k -K -E -r -l 1 -p -N -F --convert-links -H -Dcdn.shopify.com,v.shopify.com,www.yoursite.com,your-site.myshopify.com --restrict-file-names=windows https://www.yoursite.com/

The -D option specifies all the hosts that WGET should download the resources from in local files. Resources of hosts not specified in the option will be kept as is.

The issue for now is that I don’t know how to make it download dynamic images in data-src attributes, such as the images that will only show when scrolled into view.

Other that that, it’s a perfect command.

{ 0 comments }

This is a collaborative project with one of my friends in college who owns a fairly large machining workshop in Jiangsu, China. He came to me looking for help to build a new site for his business to reach new customers.

While I can do exactly what he asked, I believe it’s much better to start from the industry level rather than from a business level.

Therefore I created the directory of machine shops and machining services, https://www.GetMachining.com.

All the days and dates are approximate.

Day 1 (2019.10.25)

Created the directory with the listingpro WordPress theme for which I’d rate 3.8/5 after paying $69. I can live with it now but if I’m starting a new project of similar purpose, I’d use my in-house site script for low-maintenance and evergreen-ness which is the key to cash flow in the long term.

WordPress and its themes / plugins are great to start something but it’s becoming unpredictable with regards to updates and version compatibilities among all the themes and plugins maintained by independent teams. It’s very easy to break a working site 1 or 2 years into the future when you have to update something.

Day 2 (2019.10.26)

Used https://datasn.io to get the listings data from Google Maps via the API and imported in the Get Machining site. Now we have a total of 23,000 entries of machining shops in the United States.

Looking to get more in other countries such as UK, Germany, China, and India.

Day 3 (2019.10.27)

Tweaked the site and the theme a bit so it’s more usable.

Day 9 (2019.11.2)

Added the site to Google Analytics and then Google Search Console.

As always, if you have any questions of insights of this, leave comments.

{ 0 comments }

As someone at NamePros suggests with some of my exact match .com names, I created this affiliate site with the domain MensWinterBoots.com and see what kind of business or cash flow I can get.

Exact match domains used to dominate in Google search results but no more. I’m skeptical of how this would turn out but I try to build an as beautiful and usable site as possible with Shopify and the Spreadr app.

Imported thus far about 100 products from the category of winter / snow boots for men on Amazon. All look good with the free Shopify theme Debut which I highly recommend. I talked with some of the high selling store owners and they seemed to use this theme quite a bit.

Also used Google Fonts to find the perfect typography and created the Men’s Winter Boots logo for the site.

Installed Google Analytics for traffic analysis and added the site in Google Search Console for rankings monitoring.

I will update how the site performs in this blog and document exactly what I have done. Make sure you bookmark or subscribe to Kavoir.

Day 1 (2019.10.25)

Google indexed the site but it’s far from ranking in the results according to https://www.serprobot.com/serp-check.php

Day 3 (2019.10.27)

I don’t have a screenshot but Google indexed slightly over 200 pages on 2019.10.27 by searching site:menswinterboots.com

Day 4 – 5 (2019.10.28-29)

Added a few more navigations to the site so it’s a breeze to find any boot, by brand, by use cases, by color, etc. and created couple of collections by popular keywords found via Google auto-completion and related searches, e.g. affordable men’s boots, clearance men’s boots.

Started a tiny SEO campaign for 15 days by one of my outsource buddies in Pakistan for $100.

Day 9 (2019.11.2)

Google indexed 688 pages of the site. Organic impressions and clicks are on their way according to Google Search Console:

Day 20 (2019.11.13)

Search traffic seems to be picking up and CTR is not bad. Top impressions and clicks are from search of “men’s winter boots clearance“.

Google Search Console

However, the number of total indexed pages in Google dropped to 85:

Google indexed pages dropped to 85

{ 2 comments }

When you have multiple domains under the same Office 365 admin account, e.g. domain1.com, domain2.com, etc., you can’t directly create these emails:

  • support@domain1.com
  • support@domain2.com

Which would give this error when you try to create emails by the same name already used by another domain:

Now you can have a little circumvention to get around this by first creating the email with a unique local name and then creating an email alias to use the name you want.

Do as the following:

Done!

{ Comments on this entry are closed }

A top level domain is added to WordPress Network / Multi-sites via the Domain Mapping plugin. However since the domain is not in the cPanel as an addon domain, AutoSSL will not issue SSL certificate for it.

The solution is, after adding the top level domain in the Domain Mapping plugin, add it in cPanel as an alias domain for the WordPress Multi-site main domain (independent cPanel account).

Therefore AutoSSL will issue and install an SSL certificate for the alias domain. Go to “Manage AutoSSL” in WHM and “Run AutoSSL For All Users” to manually request SSL certificate for the alias domain.

It may take some minutes for the new certificate to be installed.

Problematic step: Previously I did below but it seemed to mess backend dashboard and kept auto-switching between http:// vs. https://, logging out again and again. So DON’T DO THIS? However, it might be a Chrome redirect cache issue though. I’m doing this now and will keep an eye on any potential issue.

Go to WordPress Multi-site: “My Sites” => “Network Admin” => “Sites” => Click “Edit” of the sub-site, and change the Site Address (URL) to the top level domain URL like this:

https://www.example.com/

Click “Save Changes“.

Now install the Really Simple SSL plugin, network activate it, and choose per site mode.

Go to the sub-site dashboard: “Settings” => “SSL” => Activate SSL

Done!

If you haven’t done the above problematic step, below is optional and NOT required at all, otherwise below is required.

You can force HTTPS on the top level domain in .htaccess of your WordPress network installation:

RewriteEngine On
RewriteBase /

RewriteCond %{HTTP_HOST} yourtopleveldomain\.com
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

# BEGIN WordPress
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule . index.php [L]

{ Comments on this entry are closed }

My Personal Review: CheapSSLShop.com

by Yang Yang on February 9, 2019

This is my personal review of site CheapSSLShop.com which I personally use.

It’s one of the most affordable SSL vendors I can find on the Internet. I’ve been personally using it since 2012.

The price is good and the delivery is fast and easy.

You need some expertise to get the SSL certificates installed but with support from my host, there’s nothing to worry about for me.

Cheap SSL Shop was also able to process full refunds to me when I messaged them about my mis-order of SSL certificates I didn’t need. This is something you don’t see everyday but they do it nonetheless.

A trustworthy supplier overall, it’s highly recommended.

{ Comments on this entry are closed }

Code folders may be distributed across different locations and paths but you want to manage them in one Eclipse project. It’s easy to achieve this by linking code source in your Eclipse project.

  1. Right click on project
  2. Click “Properties”
  3. Select “PHP” > “Build Path”
  4. Click “Link Source…”
  5. Click “Browse”
  6. Select the code folder to link and click “OK”

Change array initializer indentation size

https://stackoverflow.com/q/13108241/49318

Twig syntax highlighting

http://twig.dubture.com/installation/

{ Comments on this entry are closed }

Don’t control

by Yang Yang on June 13, 2018

Most of us are loss-averse. We worry too much about failing and losing. We spend too much valuable resources in identifying the wrong things to do so as to make sure we don’t do them.

We vigorously look for the right thing to do.

We want control.

We believe business success is achieved by maintaining order of everything so that everything is under control. Otherwise we’d lose control and crash.

Is that really so?

After 10 years of entrepreneurship, the one thing I’m certain now is that this mindset is wrong.

To get great things done, one must be glad to lose control.

Let things run wild.

Let your business get out of control.

If everything’s under control, you are just not moving fast enough.

The most successful businesses are good at NOT controlling. Instead of making sure everything goes as planed and nothing bad happens, they focus resources on setting off the fire that grows exponentially. Yes, fires are dangerous. Fires can get out of control fairly quick. But that’s the beauty of it.

Let it finish the job. Then you just call 911. Investors will be happy to clear it up for you.

If there’s one advice for creating something big, it’s this one:

Don’t control it.

{ Comments on this entry are closed }

Misdress is one of our wedding fashion brands. We have seen an increase of general conversion rate from 0.9% to 1.3% after we have implemented these for the site:

  1. Adding a phone number in the site footer
  2. Adding a reviews module on the product pages
  3. Adding important information links on the product pages, e.g. Returns, Size Charts, Shipping Time, etc.
  4. Adding bulk discount table immediately below the add to cart button.

The key is to make you as a business a real one and make visitors believe it. Show your visitors you are serious about your offer and you are committed to delivering it.

Some more tests we will do in the next conversion rate optimization & measurement include adding customer testimonials / reviews on the homepage, and adding team photos (with faces) to our about page.

Hope this could be something useful to you guys who are still listening to me.

{ Comments on this entry are closed }

Information as Deck of Cards

by Yang Yang on August 5, 2016

Found this site when searching for answer to some git issues. It turns out to be a very nice way to teach stuff, simple and efficient:

https://githowto.com/setup

A guide like this should be as easy to write as it is easy to learn from.

The key here is to associate problem / question / issue with a straightforward solution / answer in a very simple manner. Talk is expensive. We should talk as less as possible.

Deprive of any words that your tutorial or guide can live without but leave only those that are vital to the actual solution / answer.

A full tutorial or guide should be comprised of a list or a network of standalone articles that are simple yet powerful in addressing 1 – 3 problems each. They are more like a deck of cards wired together linearly or hierarchically that the readers can search or navigate back and forth.

Each article / card should be no more than 2 minutes of reading. This helps establish learning milestones for the readers thus keep them motivated to continue because each learning session is easy to finish and apply.

{ Comments on this entry are closed }