Showing posts with label development. Show all posts
Showing posts with label development. Show all posts

2013/12/02

#37. Firefox and other browser blocks insecure content

You have a website and firefox or other browsers block your ads or other content?
And it also shows an alert about insecure content?

Maybe you are using https in your website, then probably the cause is that you are serving this content without security (http) and browsers usually complain about it.

A simple way to fix this common mixed content error is removing the protocol from the url, so if you have an url to your content like src="http://yourcontent/contentpage" leave it like src="//yourcontent/contentpage". This way the browser will connect using the same protocol as the container page and allowing the content.

2013/07/09

#35. Use Github for Windows behind corporate web proxy

github logo

For some time I wasn't able to connect to Github with the windows official app at work. At work we have a corporate web proxy that filters some content, and after not seeing any option to configure the proxy on the app I gave up.

But the other day I wanted to share a simple project to ping websites, WebsitePinger and I couldn't upload the code, doing a small research I found out that simply to configure GitHub for Windows, you just need to edit the .gitconfig file typically found at C:\Users\.gitconfig or C:\Documents & Settings\.gitconfig and add

[http]
proxy = http://yourcompanyproxy.com:8080

[https]
proxy = http://yourcompanyproxy.com:8080



I shared this on stackoverflow where a fellow companion was also not able to connect through proxy and seems that he did not find a working answer for him, I shared my resolution as probably someone will have the same problem as mine.

2013/05/22

#31. LINQ - Find duplicates in a list


After reading some of the Linq Pocket Reference from (O'Reilly) I have become quite the expert in LINQ in my office. A partner asked me how to find if a list has duplicates, that he did a fast search online but could not find a simple answer, so I coded him a simple test that shows us how to find duplicates in a list with LINQ, which you can find below. Also, if you want to check for duplicates in a class list you only need to group by with the field you want to use to find the duplicates, easy as that.

Feel free to ask for more in the comments. Thanks for reading!