How to see what metadata Google has about you

If you’re like most people, you have a Google account and notice very effective targeted advertisements.

It’s what Google have been so successful with, you sign up for their services, they learn a little about you then start running advertisements targeting what they know about you. But what exactly do they know?

You can see this, and disable certain elements of their data collection using https://history.google.com

When you first log into https://history.google.com the first thing you will notice is all your search history – creepy !

GoogleHistory1

I personally suggest you use the select all and remove items options to clear this history – after all, even you don’t need this level of data.

Click on the settings cog at the top right on the window and select ‘Settings’

Click on ‘Show more settings’

From here you will be able to access various sets of metadata Google has for their services – such as YouTube.

The most interest one for Google Android users would be ‘Places you go’ which plots your movements using GPS locations.

For each you can use ‘Manage History’  to view and clear the data, and the blue toggle to pause the history.

GoogleHistory2

Word 2013 – How to remove links to other files

If you see the following message when opening a Word document it means the document has been linked to another document, most likely a spreadsheet.

“This document contains links that may refer to other files. Do you want to update this document with the data from the linked files?”

Word2013-LinkExcel5

See Word 2013 – How to link an Excel spreadsheet to see how these documents are linked.

Issues can occur when the linked file has been moved or delete. The linking also stops Adobe Acrobat from combining the file with other files.

The steps below show how to unlink the Word document from the other file.

How to unlink files from a Word document

  1. With Word open, click on the ‘FILE’ menu then click on ‘Options’
  2. Word2013-AutomaticallyUpdateLinkedFile1
  3. On the left hand side click on ‘Quick Access Toolbar’
  4. Under ‘Choose commands from’ select ‘All Commands’
  5. Scroll down until you see ‘Edit Links to Files’ and select it
  6. Click on the ‘Add’ button to add it to the quick access toolbar.
  7. Click ‘OK’ to save the changes,
  8. Word2013-UnlickFiles1
  9. You’ll now find a new icon for ‘Edit Links to Files’ in the quick access toolbar at the top left of Word.
  10. Word2013-UnlickFiles2
  11. Click on the ‘Edit Links to Files’ icon
  12. The ‘Links’ window will open and will list all the files that are linked to the document.
  13. Select the file you want to unlick and click ‘Break’
  14. Click ‘OK’ to save the changes.
  15. Word2013-UnlickFiles3
  16. The file will now be unlinked. It will remain in the Word document as a picture.

Word 2013 – How to disable update linked document message

If you see the following message when opening a Word document it means the document has been linked to another document, most likely a spreadsheet.

“This document contains links that may refer to other files. Do you want to update this document with the data from the linked files?”

Word2013-LinkExcel5

 

The steps below show how to disable the message – it will leave the link between the two documents, but will no longer prompt.

  1. Open Word, click on the ‘FILE’ menu then click on ‘Options’
  2. Word2013-AutomaticallyUpdateLinkedFile1
  3. In the left hand menu, click on ‘Advanced’
  4. Scroll down to the ‘General’ section
  5. Un-tick ‘Update automatic links at open’
  6. Word2013-AutomaticallyUpdateLinkedFile2
  7. Click ‘OK’ to save the changes.

 

Word 2013 – How to embed an Excel spreadsheet

The steps below show how to embed an Excel spreadsheet in a Word document. This allows the data in the Excel spreadsheet to be updated outside of the Word document, while keeping the latest data available to the Word document.

For this example we’ll use two files –

  • Doc1 – the Word document
  • Book1 – the Excel document

How to link a Word document with an Excel spreadsheet

  1. In Windows Explorer, open the folder that contains the spreadsheet and right-click on it and select ‘Copy’
  2. Word2013-LinkExcel1
  3. Open the Word document, select the place where you want to embed the spreadsheet
  4. On the ‘HOME’ ribbon, click on the arrow below ‘Paste’ and click on ‘Past Special’
  5. Word2013-LinkExcel2
  6. Click on‘Past link’, select ‘Microsoft Excel’ from the list and click ‘OK’
  7. Word2013-LinkExcel3
  8. The Excel spreadsheet is now embedded into the Word document.
  9. You can update the Excel spreadsheet from Word by double clicking on the table – this will open a new Excel window.
  10. Word2013-LinkExcel4
  11. When the Word document is opened you will see a prompt that reads:
  12. “This document contains links that may refer to other files. Do you want to update this document with the data from the linked files?”
  13. Clicking yes will load the latest data from the spreadsheet.
  14. Word2013-LinkExcel5

Word 2013 – How to link an Excel spreadsheet

The steps below show how to link a Word document with an Excel spreadsheet. This allows the data in the Excel spreadsheet to be updated outside of the Word document, while keeping the latest data available to the Word document.

For this example we’ll use two files –

  • Doc1 – the Word document
  • Book1 – the Excel document

How to link a Word document with an Excel spreadsheet

  1. In Windows Explorer, open the folder that contains the spreadsheet and right-click on it and select ‘Copy’
  2. Word2013-LinkExcel1
  3. Open the Word document, select the place where you want to embed the spreadsheet
  4. On the ‘HOME’ ribbon, click on the arrow below ‘Paste’ and click on ‘Past Special’
  5. Word2013-LinkExcel2
  6. Click on‘Past link’, select ‘Microsoft Excel’ from the list and click ‘OK’
  7. Word2013-LinkExcel3
  8. The Excel spreadsheet is now embedded into the Word document.
  9. You can update the Excel spreadsheet from Word by double clicking on the table – this will open a new Excel window.
  10. Word2013-LinkExcel4
  11. When the Word document is opened you will see a prompt that reads:
  12. “This document contains links that may refer to other files. Do you want to update this document with the data from the linked files?”
  13. Clicking yes will load the latest data from the spreadsheet.
  14. Word2013-LinkExcel5

Google Analytics – How to exclude query parameters

One of the key bits of information Google Analytics collects is the URL that was loaded.

Sometimes a URL may have one or more query parameters, for example:

www.domain.com/?query1=1&query2=2&gf_token=123

By default Google will collect the full URL with all the query parameters.

Sometimes this is useful, for example if the query parameter shows search terms people use in your website – and sometimes it can be bad, creating duplicate page loads in your Analytics data or even worse including personal identifiable information.

If you do not already know, the terms of service for Google Analytics makes it critical that personal identifiable information is never collected through Google Analytics.

The following steps detail how to exclude specific query parameters from being collected by Google Analytics. In this example we will be excluding the gf_token query parameter – which is used by the WordPress Gravity Forms plugin.

  1. Sign into your Google Analytics account – http://www.google.com/analytics
  2. At the top of the window click on ‘Admin’
  3. GoogleAnalytics-ExcludeQueryParameter1
  4. Under ‘Account’, ‘Property’ and ‘View’ make sure the correct account is selected
  5. Then click on ‘View Settings’
  6. GoogleAnalytics-ExcludeQueryParameter2
  7. Now under ‘Exclude URL Query Parameter’ enter the query you want to exclude. Additional query parameters can be added by separating with a comma. For example:
  8. gf_token,query1,query2
  9. GoogleAnalytics-ExcludeQueryParameter3
  10. Click ‘Save’ at the bottom of the screen to save the changes.
  11. Analytics will now stop collecting the information for the specified query parameters. Please note that past data will not be affected.

Internet Explorer – How to hide select options using jQuery

Internet Explorer does not support using the ‘display: none’ style on OPTION elements inside a SELECT list.

For example, the below would work in FireFox and Google Chrome but not Internet Explorer.

<select>
<option value=“volvo”>Volvo</option>
<option style=”display: none” value=“saab”>Saab</option>
<option value=“mercedes”>Mercedes</option>
<option value=“audi”>Audi</option>
</select>

Since Internet Explore will not hide an option you instead need to disable it. In Internet Explorer this will color the option light grey and not allow it to be selected.

The following jQuery will work in Internet Explorer, Firefox and Goolge Chrome (as well as other browsers). it will hide and disable the option:

$('select option[value=saab]').attr('disabled', 'disabled').hide();

Note – replace $ with jQuery if you are using WordPress.

jQuery-HideSelectOption1

If you do not already have jQuery loaded on the page, you will need to include it. The easiest way is to include the following line in your page head.

<script src="//code.jquery.com/jquery-1.11.2.min.js"></script

To display or enable the option again, using the following jQuery:

$('select option[value=saab]').removeAttr('disabled').show()

jQuery-HideSelectOption2

 

Reference: http://stackoverflow.com/questions/20373558/options-with-displaynone-not-hidden-in-ie (solution provided by Gev Mar 6 at 11:40).

WordPress – Make menu items to open in a new window (target _blank)

The following steps detail how to make a menu item in WordPress open in a new window, that is the links have the the target=’_blank’ attribute.

This is done by adding additional screen options to the menu editor screen.

  1. In the WordPress administration (wp-admin) open ‘Appearance’ -> ‘Menus’
  2. WordPress-MenuTargetBlank1
  3. At the top right of the window, click on ‘Screen Options’
  4. Under ‘Show advanced menu properties’ place a tick next to ‘Link Target’
  5. WordPress-MenuTargetBlank2
  6. The menu items will now have an additional property called ‘Open link in a new window/tab’
  7. Place a tick for the menu items you want to open in a new window.
  8. WordPress-MenuTargetBlank3
  9. Click ‘Save Menu’ to save the changes.
  10. The menu items will now have the target=’_blank’ attribute, making them open in a new window.

Windows 8 – How to convert CDA audio disc to MP3 files

The steps below detail how to convert an audio disc to MP3 files using Windows Media Player.

Fun fact – the CDA files you see in an audio disc are nothing more than shortcuts to the tracks on an audio disc.

  1. Open Windows Media Player (Open the Windows menu, type ‘Windows Media player’ and click on the icon)
  2. Windows8-AudioDiscToMp3
  3. Press ‘Alt’ on the keyboard and open the ‘Tools’ menu then ‘Options’
  4. Windows8-AudioDiscToMp3-2
  5. Open the ‘Rip music’ tab
  6. Take note of the ‘Rip music to this location’ location – this is where your converted audio discs will be saved
  7. Change the ‘Format’ setting to ‘MP3′
  8. Optional: change the ‘Audio quality’ to a higher setting, for example320 kbps.
  9. Windows8-AudioDiscToMp3-3
  10. Click ‘OK’ to save the settings.
  11. In the left hand menu, you will see a CD icon that represents the audio disc that is in your CD drive – right click and click on ‘Rip CD to library’
  12. Windows8-AudioDiscToMp3-4
  13. Select ‘Do not add copy right protection to your music’ and ‘I understand …’
  14. Click ‘OK’ to start the process
  15. Windows8-AudioDiscToMp3-5
  16. The CD will begin being ripped to your library, it will take 10 – 20 minutes to complete.
  17. Windows8-AudioDiscToMp3-6
  18. When done will find the folder of MP3 files in the location noted in step 6.

WordPress – Use one variable multiple times using $wpdb->prepare

Question

How do you use a variable multiple times when using $wpdb->prepare   ?

Answer

If you’re prepared SQL statement needs to refer to a variable more than once you need to include it multiple times.

For example, the SQL query below refers to the user_id twice – both for the use_id and conrtributor_use_id column

SELECT id, title, user_id, contributor_user_id WHERE user_id = 1 OR contributor_user_id = 1

To prepare this statement you would need to do this

$wpdb->prepare("SELECT id, title, user_id, contributor_user_id WHERE user_id = %d OR contributor_user_id = %d", $user_id, $user_id);