w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Creating a hexagonal menu using css
http://codepen.io/anon/pen/fGjnK Here is exactly this menu from your site. If something is unclear, use google. There are well documentet site for CSS statements.

Categories : CSS

Creating a menu like on Ebay.com
Super easy fix, just remove :first-of-type in .ulclass li:first-of-type:hover .ulsubmenu { display:block; } Obviously you'll need to add the rest of the submenus before those will work. Working copy here

Categories : Jquery

Creating a pop out menu without a nav bar button
Why don't you put this code in your button action: UIActionSheet *actionSheet = [[UIActionSheet alloc]initWithTitle:@"Share" delegate:self cancelButtonTitle:@"Cancel" destructiveButtonTitle:nil otherButtonTitles:@"Take Photo",@"Choose Existing", nil]; [actionSheet showInView:self.view]; This view will come up from the bottom of the screen:

Categories : Iphone

Creating a popup menu at runtime
You have to actually create instances of a class in Delphi before you can use them. The following code creates a popup menu, adds a few items to it (including an event handler for the click), and assigns it to the form. Note that you have to declare (and write) the HandlePopupItemClick event yourself like I've done). In the interface section (add Menus to the uses clause): type TForm1 = class(TForm) // Double-click the OnCreate in the Object Inspector Events tab. // It will add this item. procedure FormCreate(Sender: TObject); private { Private declarations } // Add the next two lines yourself, then use Ctrl+C to // generate the empty HandlePopupItem handler FPopup: TPopupMenu; procedure HandlePopupItem(Sender: TObject); public { Public de

Categories : Delphi

Creating Drop Down Menu on click CSS
You will need to do this using javascript and registering a click event handler to perform your action. If you're new to everything then you should look for some javascript tutorials (don't use W3Schools, look elsewhere) and then look at some jQuery tutorials as jQuery simplifies tasks like these.

Categories : Javascript

Creating an instance of a menu item
You have to do it this way in your Activity class: @Override public boolean onCreateOptionsMenu(Menu menu) { super.onCreateOptionsMenu(menu); MenuInflater inflater = getMenuInflater(); inflater.inflate(R.menu.main, menu); // inflate your menu resource if (menu != null) { MenuItem color = menu.findItem(R.id.color); if (color != null) { color.setChecked(false); } } return true; }

Categories : Android

Creating simple CSS multilevel menu
Here is a CSS only solution as the OP requested, using tabindex DEMO http://jsfiddle.net/kevinPHPkevin/phzuC/2/ #menu li > ul { display:none; } #menu li:focus > ul { display:block; } li { outline: 0; } EDITED Here is a jQuery solution should you ever need it. It keeps the submenus open and it's simple to implement. 11 lines of code. DEMO http://jsfiddle.net/kevinPHPkevin/phzuC/5/ $(document).ready(function() { $(".nav-top > li").click(function(e) { if($(this).find('ul').hasClass('expanded')) { $(this).find('ul').removeClass('expanded').hide(); } else { $(this).find('ul').addClass('expanded').show(); } }); $('.nav-top a').click(function(e){ e.preventDefault(); }); });

Categories : CSS

Creating A Dropline Style Menu
I've updated the code http://jsfiddle.net/38c6q/1/ replaced this $("#sub-link-bar").stop().animate({ height: "40px"}, function(){ $(that).find(".sub-links").show(); }); with $('#sub-menu').html( $(that).find(".sub-links").html() ) To have them float next to each other, you can add this CSS .sub-menu li{ display:block; padding:0; margin:0; float:left; } And to add some colors and backgrounds to links, add some CSS like this .sub-menu a{ display:block; margin:0 5px; padding:5px; text-decoration:none; Color:#333; } .sub-menu a:hover{ background:#333; color:#fff; } updated Demo at http://jsfiddle.net/38c6q/4/

Categories : Javascript

Creating nested menu in django-cms
The nesting of your pages isn't dictated by template inheritance, it's decided by how you lay out your pages in the django-cms admin interface. You need to place the pages you create in the hierarchy that you wish to reflect in your menu:

Categories : Misc

Creating a dropdown menu using CSS and HTML
The problem is the container width is defined at 300px #navigation ul li > div.product { width: 300px; } And its child elements are taking up 100% of that space. So you need to make sure they have room to float left. #navigation div.col { float: left; height:200px; width: 25%; } Hopefully that helps with your question. Fiddle

Categories : HTML

Creating a responsive menu in Bootstrap
Set your dropdown menu css to .dropdown-menu{ width: 66%; overflow:hidden; } You width becomes fixed as em is not much capable of resize at some level it is more useful in font-size, So menu is unable to resize. And also before setting width try to check you drop-down menu by removing width style, because i think bootstrap handle it itself. In addition bootstrap provide css file responsive.css try make use of it.

Categories : CSS

Creating Menu Slider Android
While the link you provided offer a pretty good tutorial, however it's not great for everyday use ( i tested it my self ), i would suggest using this library instead ; https://github.com/jfeinstein10/SlidingMenu The most functional 3rd library provided by jfeinstein offers a pretty easy way to implement it, and you will able to use it in no time! Good Luck!

Categories : Android

Creating an game menu in OpenGL tutorials
Try the following link which will show you complete walkthrough for designing a tetris game in opengl. Read it till end and then go your own way:- http://www.codeproject.com/Articles/30775/TetroGL-An-OpenGL-Game-Tutorial-in-C-for-Win32-pla

Categories : Opengl

Creating a single menu across multiple web pages - without PHP
I think what you want to do is extend a template. Make a file called something like base.html. In this file, put your menu, or anything else you want across all of your pages. Then, include something that looks like this. {% block content %} {% endblock %} In the rest of your templates (for actually serving the content), you have to include the line {% extends "base.html" %} as the very fist line. Then surround your content with: {% block content %} Your content Here {% endblock %} For more information see https://docs.djangoproject.com/en/dev/ref/templates/builtins/#extends and https://docs.djangoproject.com/en/dev/topics/templates/#template-inheritance

Categories : HTML

creating a dynamic menu using two mysql tables
I've create the following tables. parents +----+------+-----------+ | id | link | label | +----+------+-----------+ | 1 | veg | Vegetable | | 2 | fru | Fruit | +----+------+-----------+ childs +----+-----------+--------+---------+ | id | parent_id | link | label | +----+-----------+--------+---------+ | 1 | 1 | beets | Beets | | 2 | 1 | carrot | carrots | | 3 | 2 | apple | Apples | +----+-----------+--------+---------+ One way to do this is to select all the parents, and loop through each one getting their childs. Here is some pseudocode. I may have messed up the ul/li nesting, but you should get the idea. // Start by getting all the parents. $parents = // SELECT * FROM PARENTS; // Loop through all the parents. @foreach ($parents a

Categories : PHP

C++ Win32 Creating a Popup Menu From Resource
Founds the solution: HMENU hMenu = LoadMenu(NULL, MAKEINTRESOURCE(IDR_POPUPMENU)); hMenu = GetSubMenu(hMenu, 0); and resource: IDR_POPUPMENU MENU DISCARDABLE BEGIN POPUP "TEST" BEGIN MENUITEM "Test", IDM_TEST MENUITEM "Close", IDM_CLOSE END END Just had to start the resource entry with a beginning sub menu, TEST does not display, only its menu items do. Thanks.

Categories : C++

Slide in menu creating horizontal scroll bar
Like this DEMO CSS #slideIn { background:red; width: 200px; float: right; margin-right: -180px; margin:0; padding:0; }

Categories : Jquery

Creating Dropdown Menu from Model using Django
Write a new view in views.py Create a new form class with a ChoiceField Populate this ChoiceField with the data from your database via PhoneTable.objects.all() Create a template, say phoneview.html Render this template from your view and send the form as a template parameter If you don't know how to do these things read Django app tutorial

Categories : Python

Creating a CSS-only dropdown menu - one item disappears
Because your dropdown menu is contained within #header, which has the following rule: #header { overflow: hidden; } It cuts off the rest of the menu. Consider removing the overflow: hidden.

Categories : CSS

Creating a delegate to change views from a menu
Your SlidingMenuDelegate protocol needs some (optional) methods such as slidingMenu:didSelectOption:. Also, I would define an enum or something that specifies all of the options that the menu provides. Then in your tableView:didSelectRowAtIndexPath: method, you would do if ([self.delegate respondsToSelector:@selector(slidingMenu:didSelectOption:)]) { SlidingMenuOption option; switch (indexPath.row) { case 0: option = SlidingMenuFooOption; break; case 1: option = SlidingMenuBarOption; break; // ... } [self.delegate slidingMenu:self didSelectOption:option]; } Finally, your delegate would do something in response to this slidingMenu:didSelectOption: message (e.g. set the title of the navigation controller).

Categories : IOS

An issue when creating a pop-up menu w.r.t to a parametr via loop
In Qt code, you shouldn't be using std::stringstream or std::string. It's pointless. You have a crashing bug by having the menu on the stack and giving it a parent. It'll be double-destructed. Don't use the synchronous blocking methods like exec(). Show the menu asynchronously using popup(). In order to react to the actions, connect a slot to the menu's triggered(QAction*) signal. That way you can deal with arbitrary number of automatically generated actions. You can use the Qt property system to mark actions with custom attributes. QAction is a QObject after all, with all the benefits. For example, you can store your index in an "index" property. It's a dynamic property, created on the fly. Here's a complete example of how to do it. main.cpp #include <QApplication> #include <

Categories : C++

Creating different classes for each dynamicly created menu
Well, just use your $section and modify this. Using ZF2, you'd use the Filter CamelCaseToDash $filter = new endFilterWordCamelCaseToDash(); $classFiltered = strtolower($filter->filter($class);) Now you can use $classFiltered for your CSS-Class assignment. And since you've mentioned both frameworks in your tags. In case you are using ZF2, that code is horrible :D You should create yourself a ViewHelper that renders the Menu. Evan Coury has written a very easy introduction on how to do that. Aside from that, you don't need a static call to some Application::getInstance(). If you want to gain access to the config you do this via the ServiceLocator. In a Controller this would look like this: $config = $this->getServiceLocator()->get('config'); If you need the config in

Categories : PHP

creating pull down menu in windows phone 8
While it can be done on your own, it's a pain to do well, and Telerik has already done this - check out their Data Bound ListBox control - http://www.telerik.com/products/windows-phone/overview/all-controls/databoundlistbox.aspx

Categories : Windows Phone 8

Creating a Selection Menu using Cocoa Touch and Objective C
How about using a UINavigationController and pushing an UITableViewController with a list of themes on the navigation stack? You are not limited in the number of themes you can offer and it should be pretty easy to do. Or you could use [UIViewController presentViewController:animated:completion:] with modalTransitionStyle set to UIModalTransitionStyleFlipHorizontal.

Categories : Objective C

Creating a pull down menu with folders in NUKE python
The nuke.Panel enumeration pulldown cannot handle strings in the values. You would have to replace any spaces with another character(s) and then create the pulldown. p = nuke.Panel('my custom panel') paths = [i.replace(" ", "-_-") for i in os.walk('E:').next()[1]] p.addEnumerationPulldown('my choices', paths) ret = p.show() Ultimately, it's probably better to use a PythonPanel instead if it can fit your needs. It can handle spaces in an Enumeration_Knob attached to the panel. import os import nuke import nukescripts p = nukescripts.PythonPanel("foo") k = nuke.Enumeration_Knob("bar", 'bar', os.walk('E:').next()[1]) p.addKnob(k) p.show()

Categories : Python

Creating dropdown menu with submenus appearing on rollover
I tend to make the top level li's inline-blocks for this and then make the sub-menus blocks. Then just use of the css :hover selector and some absolute positioning of the sub-menus does the job. Made a fiddle for you to demonstrate. http://jsfiddle.net/jaredkhan/EuH8P/1

Categories : HTML

Rendering problems while creating a menu in Android Studio
It looks you have some attributes in your menu that aren't valid - they're layout attributes, not menu attributes. Try this: <?xml version="1.0" encoding="utf-8"?> <menu xmlns:android="http://schemas.android.com/apk/res/android"> <item android:id="@+id/new_game" android:icon="@drawable/magnify" android:title="New Game" android:showAsAction="ifRoom" /> <item android:id="@+id/help" android:icon="@drawable/magnify" android:title="Help" android:showAsAction="ifRoom" /> </menu>

Categories : Android

Creating a 'yes' or 'no' menu in UNIX bash shell scripting
Does your script even run? Doesn't look like valid bash-script to me. If is not a valid keyword, but if is. Also, tests go inside angle-brackets [ ], those are not optional. Moreover you forgot the closing fi. And another thing, it's not quite clear to me what you're testing for. Is directorypathANDfilename a variable? In that case you have to reference it with the $. The snippet would probably work better like this: #!/bin/bash if [ -f "$directorypathANDfilename" ] ; then read -p "A file with the same name exists, Overwrite it? Type y/n?" yesorno case "$yesorno" in y*) therestore ;; n*) echo "File has not been restored" ;; esac fi

Categories : Bash

Dynamically creating a floating context menu with listener for each item?
If the list of numbers is reasonably short from the UX point of view (i.e. users don't want to search/filter the list), you can use a traditional single-choice list AlertDialog. You just need to modify the example from the docs slightly: final List<Integer> list = new ArrayList<Integer>(); list.add(1); list.add(2); list.add(3); final CharSequence[] numbers = new CharSequence[list.size()]; for (int i = 0; i < list.size(); i++) { numbers[i] = list.get(i).toString(); } AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); builder.setTitle("Remove entry:"); builder.setItems(numbers, new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int which) { list.remove(which); } }); builder.create().show(); As you can

Categories : Java

creating a menu after a long click event on a list view
You can call Activity.openOptionsMenu() in your click item method check here http://developer.android.com/reference/android/app/Activity.html#openOptionsMenu%28%29

Categories : Android

Trick for creating breadcrumb menu navigation for tutorial blog
One of the ideas is ... CODE NOT TESTED but should get you going .... public function get_crumbs($id, $crumbs=array()) { $query = $this->db->query("select menu_name, parent_id from mytable where id=?", array($id)); $row = $query->row_array(); $crumbs[] = $row['menu_name']; if($row['parent_id'] == 0) { krsort($crumbs); //sort array in descending order $crumbs_str = implode(' >> ', $crumbs); return $crumbs_str; } else { $this->get_crumbs($row['parent_id'], $crumbs); } } Add this function into your model class, Page_model.php In your controlloer file include your model like; $this->load->model('Page_model', 'page_model'); //Get ID $id = $this->uri->segment(4); $data['crumbs'] = $this->page_model

Categories : PHP

MenuIntem getMenuInfo() returns null when creating a context menu
android - why item.getMenuInfo is null The asker didn't mark it as the accepted answer so I don't know if it solved his problem, but it looks like you're doing the same thing he did. Register the menu as the context menu rather than the row items.

Categories : Android

Creating a checkable context menu from a list of enum values
You have used Multibinding to check your checkbox.. It will be one way unless you have done some magic in ConvertBack method of your MultiValueConverter. The thing that you want to achieve can be done like below: With your MultiBinding in place, you can bind your Menuitem to a command on your VM/codebeind and send the Menuitem's DataContext in CommandParameter. In your commmand handler you can update you static property with the command parameter. <Style TargetType="MenuItem"> <Setter Property="Command" Value="{Binding MyCommand, RelativeSource={RelativeSource AncestorType={x:Type Window}}}"/> <Setter Property="CommandParameter" Value="{Binding}"/> </Style>

Categories : Wpf

Creating a windowless menu-bar icon application in Monomac/Xamarin C#
Try specifying a .xib for the "Main nib file name' I did this some time ago, and it works fine for me. Something like this: New monomac project Created an 'AppController' class in C#: [Register("AppController")] public partial class AppController : NSObject { public AppController() { } public override void AwakeFromNib() { var statusItem = NSStatusBar.SystemStatusBar.CreateStatusItem(30); statusItem.Menu = statusMenu; statusItem.Image = NSImage.ImageNamed("f3bfd_Untitled-thumb"); statusItem.HighlightMode = true; } In MainMenu.xib, I deleted the application menu In MainMenu.xib, I added an custom object and set it's type to AppController I created my status menu in the .xib and then connected it to the AppController with an outl

Categories : C#

Modify existing code for creating menu names in an interactive shell script
Assuming you can pull out the "Add", "Delete" ... and other "titles" from the 7th line of each *.mod file, then you need to modify your script where it looks at the file a1.out somewhere before the line which seems to create the menu, namely: tr ' ' ' ' < ~/a1.out > ~/b.dat. I say "assuming" because, even though you mention awk NR==7, I don't see where you are using it in the script. In any case, if you can get the "title" from the 7th line of a given *.mod file, then you can get the menu "name" from the file name (which seems to be the way you are constructing your menu) like this: awk '{ln=length(ARGV[1]); if(NR==7) print substr(ARGV[1],0,ln-4)"..."$0}' ABC.mod outputs: ABC...Add There's may be a shorter, easier way to do this using sed, but you mentioned awk. For me at le

Categories : Bash

Twitter Bootstrap responsive menu/small devices: close/collapse menu on clicking a menu item
You can try something like.. $('.nav li a').on('click',function(){ $('.nav-collapse').collapse('hide'); }) This will work for menu links that are referencing '#'. The menu should already be collapsing if your menu links navigate to another page on the site as this would cause a full page refresh.

Categories : Twitter

css drop down menu :: sub menu is appearing within main menu after hover
You have to make some changes in the code. Fiddle css .menu{ width:70%; background:green; position:relative; } .menu ul{list-style:none;} .menu ul li{ margin-left:20px;position:relative; float:left} .menu ul ul{display:none;} .menu ul li:hover ul{display:block; background:black; position: absolute; margin: -2px 0 0 0; z-index: 11110;} .menu ul li:hover ul li{ float:none; height:20px; } Updated Fiddle Changes: display: inline-block; occupies the combined width of the inner container. position:relative; using it in menu will cause increase in the height of the outer container. you can read it at w3school

Categories : HTML

creating options menu android bottom of page on android
Seeing that you target sdk 17, you can use the SplitBar, it is an option available on the default ActionBar: http://developer.android.com/guide/topics/ui/actionbar.html#SplitBar. You need to declare it in every activity where it is needed in your manifest file, for example: <activity android:name=".MainActivity" android:label="@string/title_activity_main" android:uiOptions="splitActionBarWhenNarrow" /> Then in your onCreate function, you can also call a custom layout if you still need to display additional buttons at the top of the screen: ActionBar actionBar = getActionBar(); actionBar.setCustomView(R.layout.action_bar_custom); //load menu actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_HOME|ActionBar.DISPLAY_SHOW_CUSTOM); actionBar.setDi

Categories : Android

creating a menu/actionbar with buttons text and buttons
You should look at ActionBarSherlock. It has extensive support and helps give a more unified Android experience emulating many of the standard Google Apps on the phone. Its very customizable allowing you to place the actionbar on the top or the bottom. Likewise it allows you to place all content contained in the actionbar wherever you please.

Categories : Java

Ext.menu.Menu (Context Menu) is displayed only once on right click - Ext JS 4.2.1
Because you're creating a new menu instance every time, which means: a) Memory leak b) Duplicate component id So, remove the id from the class definition, you don't need it. Secondly, only create the menu once: onViewItemContextMenu: function(dataview, record, item, index, e, eOpts) { e.stopEvent(); if (!this.menu) { this.menu = Ext.create('MyApp.view.TreeContextMenu'); } this.menu.showAt(e.getXY()); }

Categories : Javascript



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.