bookmark_borderPHPUnit – Seeding inside your test methods

If you want to run seeders before each test you can use the artisan command in each of your test methods.

Running all seeders with:

$this->artisan('db:seed');

Running only one specific seeder:

$this->artisan('db:seed', ['--class' => 'RolesTableSeeder']);

bookmark_borderpwdquery v2 is out!

pwdquery v2

Today I am releasing the second version of my side-project pwdquery. I have spent many hours playing and manipulating the 90GB+ database, creating new scrapers, improving scripts and automating the whole process.

Remember, if you see any of your passwords in there, change immediately!

Check it out at https://pwdquery.xyz

bookmark_borderBreachCompilation Checker

It is impressive that even now there are so many big companies with poop password storage solutions! Back in 2013 Adobe had a massive password leak, followed by Google in 2016 among many others.

Not so long ago, a compilation of 1.4 billion emails and passwords have been leaked online via torrent! When I checked that this information wasn’t available on the famous haveibeenpwned.com I decided to quickly build one where people can check if their emails have been compromised. The idea is simple, just type your email and it will check if your password is on the list. The password will be displayed with some *** so that it’s not publically available (but be careful that the leaked file doesn’t hide them!).

pwdquery website

You can check it out at https://pwdquery.xyz.

bookmark_borderOpening a popup ninja from php

Checking the documentation from popup ninja plugin on how to open the popup from a link, the only available option is how to open from a blog post. But if you want to add the link in your website using php, you need to use the wordpress function do_shortcode. The documentation doesn’t show how to add a do_shortcode with content between the tags.

To open the popup with php, simply get the popup ID and use the code bellow. Just remember to change the text for your desired one.

< ?php echo do_shortcode( '[ninja-popup ID=1234]'.'text to open popup'.'[/ninja-popup]' ); ?>

bookmark_borderCustom jQuery Slide Button

The idea of this code is to create a button with a cross on the right side and when you click, it rotates the cross and expands a hidden div. To slide up you can click on the button or on a round circle on the bottom of the div.

Everything was made using HTML, JavaScript and CSS.

You can also check a demo here.

button example

Continue reading “Custom jQuery Slide Button”