Posts in this series: capture the bitcoin at tab7: pt 1 capture the bitcoin at tab7: pt 2 capture the bitcoin at tab7: pt 3 Previously, we solved the wizards’ riddles and stole their bitcoin, used the coin to find the correct preimage, deduced the mnemonic puzzle, and helped the sad pleb prevent the Giggler from enriching himself. We now find the path blocked by a gate with two locks . gate…
Posts in this series: capture the bitcoin at tab7: pt 1 capture the bitcoin at tab7: pt 2 capture the bitcoin at tab7: pt 3 Last week, we started our journey toward solving the TAB7 CTB. We ended in a wizard’s lab , with some trippy looking wizards playing scientist and a strange door looming behind them. behind door number one Going through the door puts us in a room, eavesdropping on a…
Posts in this series: capture the bitcoin at tab7: pt 1 capture the bitcoin at tab7: pt 2 capture the bitcoin at tab7: pt 3 Every year, a conference is put on in Atlanta, GA called The Atlanta Bitcoin Conference (TABconf). This year (2025) was TAB7. There is a competition put on each year called Capture the Bitcoin or CTB. The idea is to follow the clues to find a private key and use it to sweep…
I’ve been looking in to nostr recently, and I think it’s pretty neato. I wanted to participate in #nostrnovember more than I have up to this point though. In an effort to do something before the end of the month, I decided to actually create a nostr presence. After minutes of research , I created a key pair using Astral . Very quickly, though, I realized that I wanted to run my own…
After using Proton for many years, I’ve made the decision to move away from their service and migrate my email to Migadu . I’m sorry, Proton. It’s me. Not you. “But things were going so well!” Don’t get me wrong. Proton is a great service. I’d recommend it to anyone looking to move away from a service like Gmail or Yahoo Mail. I’ve been paying for it…
Bisq has a new API in the v1.9.1 release . They have provided some really good documentation on how to work with it, including some sample code in Python and Java. However, for those of us who like good programming languages, we have to figure it out on our own. Here’s a basic setup to start working with it in Rust. Completed code for this post can be found on my GitHub page . New Project…
NOTE: The source for this post is on Gitlab . Golang has strong support for concurrency. From the language itself (goroutines, channels) to constructs in the standard library (WaitGroup, Mutex), the language tries to make it easy on the developer to write concurrent programs. Let’s play with some of these by creating a program that spins up three different HTTP servers and allows for…
I figured I should write a blog post since I haven’t written anything in four years or so. I recently moved my blog from Jekyll to Hugo, and there are a few differences between the two when writing posts for them. One of which is that Hugo seems to only read the date for the post from the Front Matter in the Markdown file. Jekyll would read it from the filename. I’ve been messing…
This is the second part of the Vue.js POS tutorial series. If you haven’t read the previous posts or want to skip ahead, below are the links for each part. Create a POS System in Vue.js - Introduction Create a POS System in Vue.js - Part 1 Create a POS System in Vue.js - Part 2 Create a POS System in Vue.js - Part 3 All the code can be found in the Github repo for this series . In the…
This is the third part of the Vue.js POS tutorial series. If you haven’t read the previous posts, below are the links for each part. Create a POS System in Vue.js - Introduction Create a POS System in Vue.js - Part 1 Create a POS System in Vue.js - Part 2 Create a POS System in Vue.js - Part 3 All the code can be found in the Github repo for this series . In the previous post, we reorganized…
This is the first part of the Vue.js POS tutorial series. If you haven’t read the introduction or want to skip ahead, below are the links for each part. Create a POS System in Vue.js - Introduction Create a POS System in Vue.js - Part 1 Create a POS System in Vue.js - Part 2 Create a POS System in Vue.js - Part 3 All the code can be found in the Github repo for this series . So let’s…
If you don’t know what Vue.js is by now, then you have to check it out! In case you haven’t heard of it, here is how Vue.js describes itself on its website: Vue.js is a library for building modern web interfaces. It provides data-reactive components with a simple and flexible API. That isn’t very specific. Vue.js is a view library that updates the physical DOM based on state…
In almost every blog these days, there is a listing page of blog posts with “Read more” or ellipsis (…) to show there is more content to be viewed. Many people will use backend languages, such as PHP and Ruby, to truncate the text before it gets to the browser. That is an effective technique that works well. However, if you want to be more responsive and allow the browser to be able to change how…
Some sites allow guest users to still interact with it. Kandid.ly allows you to like a photo, for example. CodePen and JSFiddle allow you to create pieces of code without having an account. Devise by default doesn’t have anything in it for having guest users on your site. Adding this functionality is not a difficult thing to do. In fact, the Devise wiki has an article on how to do this exact…
Facebook has friends. Twitter has followers. LinkedIn has connections. A staple of a social media site is the ability to let people connect with other user in some way. It’s not very social if people aren’t interacting. Adding this to a website isn’t that difficult. It just takes some thought into what that relationship looks like on a database level. You have users who want to connect with other…
This will be a quick one. I have seen alot of posts on StackOverflow about iterating backwards through a Ruby array. Ruby, in all its beauty, gives quite a few ways to iterate through an array. Some of them are listed below: disney = %w(Mickey Minnie Donald Goofy) # using Array#each disney . each { | val | puts val } # using Enumerable#each_with_index disney . each_with_index { | val , ind | puts…
Nowadays, you’d be hard-pressed to find a PHP developer who doesn’t know about Laravel. If you are one of these people, visit the Laravel site ASAP! The framework is insanely popular in the PHP community these days because of the thought that has gone into it to make it easy to use and robust as hell! We will demonstrate its easy-of-use by building an admin interface that we can use to manage our…
Sometimes, we want to query the WordPress database for all of a post type based on some custom fields we have set. WordPress makes it easy to do. However, the syntax can be kind of cryptic due to its usage of multidimensional arrays. Hopefully, I can help clear it up for you a bit. The Issue Let’s say we have a “Show” custom post type with a name of “show.” However, we only want to display…
When creating a class, it is necessary to not only think about the functionality of the class but also how a developer will interact with that class. Making a class API easy to use is well worth the effort. Luckily, PHP ships with quite a few magic methods that can make creating a class API much easier to do. In this article, I will be talking about three of them — __get , __set , and __toString .…
Not long ago, I wrote a post about Adding Roles to Laravel Users . I like my custom solution, but I figured there had to be a better solution out there. Honestly, I should have done some looking for information before I built it. Anyways, I stumbled upon a package called Entrust written by Zizaco . This package is exactly what I was looking for! It can automatically add roles and permissions to…
Yesterday, I updated my computer to the new release of the amazing OS X operating system from Apple, code-named Mavericks. Everything went smooth, but then I realized it wiped my PHP installation away and gave me the default Mavericks installation, PHP 5.4.17. Being a web developer, I like to have the most recent version of PHP whenever I can. So naturally I decided to recompile it. I have done…
For some redirect functions in Laravel, such as Redirect::back() , a URL must be passed in your headers so the framework knows what URL to redirect back to. When testing routes that only redirect back to the previous URL, this can be confusing since there is no previous URL. It must be sent manually. When using the $this->call() function in your tests, you can supply more arguments than just the…
Sometimes a view will need a variable every single time it is loaded. Perhaps we are developing a system for tracking users, and we want to display the number of users registered in our system next to a button to display the list of users. If we have a resource controller for our User model, we would have to pass a count of users on every method in that controller that displays a view, which is…
Sometimes when creating a class others will use and extend, you may want to make sure some methods are not overridden. If it needs to be able to work with other APIs, making sure the interface of the class stays the same becomes very important. One way to do this is through the use of the final keyword in PHP. The PHP documentation describes the <code>final</code> keyword as the following: PHP 5…
Filtering in Laravel 4 is extremely easy. In case you don’t know what I’m talking about, a filter in Laravel is used on a particular route or set of routes to prevent certain people or actions from happening on a particular route. Laravel ships with a few simple but powerful filters to get you started. These include a filter to make sure a user is logged in and a one for protecting against CSRF…
Recently, I was working on a project using the Laravel framework . I wanted to retrieve a customer and then display their transactions on a page. However, I needed the transactions sorted from the most recent to the the earliest (descending order). I was using Eloquent to retrieve the customer and its transactions using the with() function. This returned a collection of transaction objects in the…
Working with dates in any language can be difficult. PHP is not any different. Though the DateTime class has tons of built in functionality, it still leaves some features to be desired. Thankfully, Brian Nesbitt has created the Carbon class . This is an extension to the basic PHP DateTime class. Laravel uses this Carbon class in its framework. By default, the timestamps that are automatically…
Recently, I worked on a project for a customer. They were using a PHP include() to render some PHP inside an HTML file. What the hell?! After some dedicated Googling, I found out that it’s possible to run an HTML file through the PHP parser to make sure that any PHP in them in rendered. It requires a line added to an .htaccess file. AddType application/x-httpd-php .html If this doesn’t work on…
Sometimes, a poorly designed form will only have one text box for a user’s whole name (first and last). Normally, though, we want to store it as first name and last name in a database for search purposes. Here is a quick way to split the value of this text input up and to check that it was enter correctly at the same time. <? php if ( ! strpos ( $_POST [ 'full_name' ], ' ' ) return false ; $names…
The one thing I love about Symfony2 over Laravel is the built in system Symfony has for creating roles. For those of you who don’t understand what I mean by roles, roles allow a developer to bar parts of an application off from users who don’t need access. A good example of this is WordPress’ Roles and Capabilities . Adding roles to Laravel is a necessity for most applications. Below is my…
Recently, I had to make a small landing page for a client at my job . I had never done anything with responsive design. So, this became a chance for me to learn something new and fun! A big problem I was having was getting the height to scale with the width. After some googling, I discovered the answer was one small line of code. Check it out below and, as always, let me know if this helped! img {…
Finally, we have come to the last post in this series…for now at least. We will talk about displaying the WPML language select list in any place your heart desires. Then we will talk about how to personalize this select list for your website. Displaying the language select list The language list can easily be displayed in the footer and the sidebar simply by changing the settings of the WPML in…
Here we are again, translating websites in WordPress using the WPML plugin. This time around we will look at making sure conditionals execute correctly no matter what language is being displayed. We will also discuss how to display custom post types that we may not want or need to be translated. Let’s get to it! Conditionals in Multiple Languages Many times in WordPress we want to display certain…
Last time we saw how to get the ID of a page very easily. We also discovered that to store characters in languages such as Chinese and Russian, we need to use a character set of UTF-8 on our databases. If none of this sounds familiar, read the post previous to this one, Tips for Translating a WordPress Website, Part One . Today, we will talk about some more things that will be necessary to…
Any web developer will tell you that moving a website from one server to another or creating a local development environment based on an existing site is not always an easy task. With many of these giant frameworks (WordPress, Drupal, Laravel, Symfony, etc.) gaining popularity, it will be necessary for a developer to know how to migrate a site quickly and effectively. Using FileZilla is effective…
Recently, I was given the task of translating a WordPress website into Chinese. I knew there were some great plugins out there for accomplishing this. Luckily, I was told that I would be using the one I consider to be the best out there-the WordPress Multilingual Plugin. Called WPML for short, this plugin can scan your website for strings that need to be translated and present them in an easy to…