207 reputation
112
bio website iamntz.com
location Romania
age 33
visits member for 5 years
seen 2 days ago
Freelance front end developer

Jul
10
awarded  Popular Question
Jun
1
awarded  Yearling
Apr
24
awarded  Nice Question
Apr
1
awarded  Popular Question
Dec
30
comment Using wp_localize_script to store the template url into a variable to use in JS
I'd say that this 'url(site.templateUrl + bg-contact.jpg) is kind of wrong. 'url(' + site.templateUrl + 'bg-contact.jpg) should work a bit better though.
Oct
11
comment Testing hooks callback
Indeed. Because on Dojo I had running time of less than 1-200ms (few tests, 20-30 max); wp test suite? enough to pull me out of flow.
Oct
11
comment Testing hooks callback
Holy crap, a lot of useful info! Thank you! Somehow I managed to miss the whole point of unit testing (until now, I was practicing PHP testing only inside of Code Dojo). I also found about wp_mock earlier today, but for some reason I manage to ignore it. What pissed me off is that any test, no matter how small it was, it used to take at least two seconds to run (load WP env first, execute the test second). Thank you again for opening my eyes!
Oct
11
accepted Testing hooks callback
Oct
11
comment Testing hooks callback
@Rarst: thanks for the suggestion, but it still doesn't work. For some reason, i think that the timing is wrong (tests are ran before init hook).
Oct
11
comment Testing hooks callback
@Sven: yes, tests are failing; i installed bin/install-wp-tests.sh (since i used wp-cli) @J.D.: RegisterCustomPostType::__construct is called (just added a die() statement and phpunit stops there)
Oct
11
asked Testing hooks callback
Jun
28
comment Using get_query_var() from a plugin
Actually rewrite rules should be added on init. But parse_query is the right hook to to retreive the bastard!
Jun
28
accepted Using get_query_var() from a plugin
Jun
28
awarded  Commentator
Jun
28
comment Using get_query_var() from a plugin
yes! this works. please add is as a post to be able to select it as the correct answer. Thanks a lot!
Jun
28
asked Using get_query_var() from a plugin
Apr
23
awarded  Scholar
Apr
23
accepted WPML Translated Term
Apr
9
awarded  Self-Learner
Apr
9
awarded  Student