composer create-project symfony/framework-standard-edition s334 "3.3.4" bin/console generate:bundle Share across multiple apps: yes namespace: Paul\ArtBundle bundle name: PaulArtBundle Target Directory: src/Refreshed the browser and sure enough I got the class not found message. The generate:bundle command is not updating the autload section of composer.json when a new namespace is introduced. Edit composer.json and:# composer.json "autoload": { "psr-4": { "AppBundle\\": "src/AppBundle", "Paul\\": "src/Paul" }, "classmap": [ "app/AppKernel.php", "app/AppCache.php" ] },Then runcomposer dumpautoloadAnd restart the server(maybe). That should fix the bundle class not found problem. I have not used the generate:bundle command is quite some time ever since the standard was to put everything under AppBundle so I don't know how long this has been "broken". But at least three questions in the last week or so indicates it was something recent. And by the way, when I refreshed the browser I got "Hello World" which threw me for a bit. Turns out the new bundle overrides the / route which is also sort of special. And in case anybody is wondering why this started happening, Symfony 3.2 changed from#composer.json "psr-4": { "": "src/" }, To "psr-4": { "AppBundle\\": "src/AppBundle" },You could always just change it back though I think spelling out individual namespaces might be "better". Not sure. And here is an issue with more details: https://github.com/symfony/symfony-standard/issues/1098 Looks like the maintainer favored a tiny speed improvement over breaking an existing command. Oh well. Symfony Flex is supposed to make everything great again
Thursday, 2 November 2017
Create Bundle In Symfony 3.3.*
Saturday, 20 May 2017
Remove the anchor tag surrounding images : WordPress
Friday, 19 May 2017
Get current page URL : WordPress
Thursday, 4 May 2017
Sunday, 30 April 2017
Adding navigation menu support to WordPress theme
While you are creating a custom WordPress theme you will that "Menus" will be dis-appear from the "Appearance" menu in dashboard of your "WordPress". It is because your theme does not have the support for WordPress menus module.
For adding this support you have add a few lines of code in your "functions.php" to call the "register_nav_menus" function, like so:
Can also check if the function exists if you desire. But if it's only for use on your own theme and you know it exists it's not really needed.
Wednesday, 26 April 2017
How to add featured image on third level of navigation?
Hello Guyz,
May, there are times when you need to show featured image in navigation of WordPress website. Here, we are sharing code for same. It, will help you to retrieve featured images for the third level of your menu. You, can make it further also or backward by doing minor tweaks in code.
If you face any issue or find it useful please comment.
Thank You,
Tuesday, 4 April 2017
Get popular tags of a category....
Put this function in functions.php of your active theme. You, can call the tags on category archive page, using shortcode [popular_post_tags] in editor or in case you want to call it using php use do_shortcode like echo do_shortcode('[popular_post_tags]');.
Thursday, 30 March 2017
Clean up WordPress header
Wednesday, 11 January 2017
JavaScript Snippets
Search This Blog
Blog Archive
Popular Posts
-
Handy snippet to get current page URL on your WordPress website. It doesn’t matter if you need it on single post, page, home, category, t...
-
mmc_unlocker_tool
-
Objective: To know and learn about various network related commands [ping, tracert, netstat, at, net, route, arp, nbtstat] and few definiti...
-
function checkOneForAll(ele, main) { var checkAll = 1; $('inpu...
Tag Cloud
Followers |