Search Results
Article: JavaScript Confirm Action Dialog
… is to use the following function. function confirmDelete(delUrl) { if (confirm("Are you sure you want to delete")) { document.location = delUrl; } } For each link that you want to use this function on just … the href with a simple bookmarklet like the following, pass the URL you want to use within this function call. <a …
… contain the full output of phpinfo(). To use this output, go to the URL http://xdebug.org/find-binary.php and paste it into the text area. … in Netbeans it will open up a web browser (as stated before) but the URL that it opens is the one that you set when you created the project. … (stored in a nbproject folder) then you should double check the URL before you start. With your project selected, open the project …
… contains a long alpha-numeric string, and this is hashed using a URL-safe sha-256 hashing algorithm to a different value when saving it … in this form, but the two main methods of interest are getCancelUrl() and submitForm(). The getCancelUrl() is used to generate the link back to the page the user came from, …
… So how do you stop this sort of thing? You can just detect the current URL that the user is looking at and see if it contains your domain … in action, which I use on #! code. This also pops up an alert if the URL does not contain your chosen URL. The idea behind this code is not to cripple the site but to force …
… { $links = []; $links[] = [ 'title' => 'Some title', 'url' => 'internal:/node/666', 'menu_name' => 'main', ] + … use Drupal\Core\Url; use Symfony\Component\DependencyInjection\ContainerInterface; … ->loadTree('category', 0, 2, TRUE); foreach ($terms as $term) { // Get URL of object. $term_url = Url::fromRoute('entity.taxonomy_term.canonical', ['taxonomy_term' …
… item of content. This system creates powerful search engine friendly URLs that can add keywords to the paths that Drupal uses to find … ->setLabel(t('Slug')) ->setDescription(t('The url slug of the entity.')); return $fields; } } Note the addition of … definitions. This will be used to store the name of this entity as a URL safe string that we can use to convert back into the entity object …
Article: Custom Post Types In WordPress 3.0
… This article relates to WordPress 3.0. Much of the code posted here won't work on previous versions and some of the information may change in newer versions. WordPress already comes with five different content … This is the standard content type and is generally the most used in a blog install. Posts tend to be aggregated onto pages but this is not …
… IS NOT NULL THEN n.type ELSE 'user' END AS 'type', ua.alias FROM url_alias ua LEFT JOIN node n ON n.nid = REPLACE(ua.source, 'node/', … for migration purposes. … Drupal 7: SQL Query To Print A List Of The URL Alias Created For Nodes And Users …
… page and by default will include the core/drupal.batch library. setUrlOptions() - Sets options that will be added to the redirect URLs. setProgressive() - This setting changes the batch to run … the form submission back to the form itself. $form_state->setRedirectUrl(new Url($this->getFormId())); } As this is a form operation we can …
… run a Google search and look at the Cached link next to the green URL text of the result. When you view the cached page Google will also … here. The class works by constructing a query string with a given URL, which it then uses to download the cached page from Google. It …