Click the Visual Media Query bar that corresponds to the media query that you want to edit.
- Dreamweaver User Guide
- Introduction
- Dreamweaver and Creative Cloud
- Dreamweaver workspaces and views
- Set up sites
- About Dreamweaver sites
- Set up a local version of your site
- Connect to a publishing server
- Set up a testing server
- Import and export Dreamweaver site settings
- Bring existing websites from a remote server to your local site root
- Accessibility features in Dreamweaver
- Advanced settings
- Set site preferences for transferring files
- Specify proxy server settings in Dreamweaver
- Synchronize Dreamweaver settings with Creative Cloud
- Using Git in Dreamweaver
- Manage files
- Create and open files
- Manage files and folders
- Getting and putting files to and from your server
- Check in and check out files
- Synchronize files
- Compare files for differences
- Cloak files and folders in your Dreamweaver site
- Enable Design Notes for Dreamweaver sites
- Preventing potential Gatekeeper exploit
- Layout and design
- CSS
- Understand Cascading Style Sheets
- Laying out pages using CSS Designer
- Using CSS preprocessors in Dreamweaver
- How to set CSS Style preferences in Dreamweaver
- Move CSS rules in Dreamweaver
- Convert inline CSS to a CSS rule in Dreamweaver
- Work with div tags
- Apply gradients to background
- Create and edit CSS3 transition effects in Dreamweaver
- Format code
- Page content and assets
- Set page properties
- Set CSS heading properties and CSS link properties
- Work with text
- Find and replace text, tags, and attributes
- DOM panel
- Edit in Live View
- Encoding documents in Dreamweaver
- Select and view elements in the Document window
- Set text properties in the Property inspector
- Spell check a web page
- Using horizontal rules in Dreamweaver
- Add and modify font combinations in Dreamweaver
- Work with assets
- Insert and update dates in Dreamweaver
- Create and manage favorite assets in Dreamweaver
- Insert and edit images in Dreamweaver
- Add media objects
- Adding videos in Dreamweaver
- Insert HTML5 video
- Insert SWF files
- Add audio effects
- Insert HTML5 audio in Dreamweaver
- Work with library items
- Using Arabic and Hebrew text in Dreamweaver
- Linking and navigation
- jQuery widgets and effects
- Coding websites
- About coding in Dreamweaver
- Coding environment in Dreamweaver
- Set coding preferences
- Customize code coloring
- Write and edit code
- Code hinting and code completion
- Collapse and expand code
- Reuse code with snippets
- Lint code
- Optimize code
- Edit code in Design view
- Work with head content for pages
- Insert server-side includes in Dreamweaver
- Using tag libraries in Dreamweaver
- Importing custom tags into Dreamweaver
- Use JavaScript behaviors (general instructions)
- Apply built-in JavaScript behaviors
- About XML and XSLT
- Perform server-side XSL transformations in Dreamweaver
- Performing client-side XSL transformations in Dreamweaver
- Add character entities for XSLT in Dreamweaver
- Format code
- Cross-product workflows
- Installing and using extensions to Dreamweaver
- In-App updates in Dreamweaver
- Insert Microsoft Office documents in Dreamweaver (Windows only)
- Working with Fireworks and Dreamweaver
- Edit content in Dreamweaver sites using Contribute
- Dreamweaver-Business Catalyst integration
- Create personalized email campaigns
- Templates
- About Dreamweaver templates
- Recognizing templates and template-based documents
- Create a Dreamweaver template
- Create editable regions in templates
- Create repeating regions and tables in Dreamweaver
- Use optional regions in templates
- Define editable tag attributes in Dreamweaver
- How to create nested templates in Dreamweaver
- Edit, update, and delete templates
- Export and import xml content in Dreamweaver
- Apply or remove a template from an existing document
- Edit content in Dreamweaver templates
- Syntax rules for template tags in Dreamweaver
- Set highlighting preferences for template regions
- Benefits of using templates in Dreamweaver
- Mobile and multiscreen
- Dynamic sites, pages and web forms
- Understand web applications
- Set up your computer for application development
- Troubleshoot database connections
- Removing connection scripts in Dreamweaver
- Design dynamic pages
- Dynamic content sources overview
- Define sources of dynamic content
- Add dynamic content to pages
- Changing dynamic content in Dreamweaver
- Display database records
- Provide and troubleshoot live data in Dreamweaver
- Add custom server behaviors in Dreamweaver
- Building forms using Dreamweaver
- Use forms to collect information from users
- Create and enable ColdFusion forms in Dreamweaver
- Create web forms
- Enhanced HTML5 support for form elements
- Develop a form using Dreamweaver
- Building applications visually
- Build master and detail pages in Dreamweaver
- Build search and results pages
- Build a record insert page
- Build an update record page in Dreamweaver
- Building record delete pages in Dreamweaver
- Use ASP commands to modify database in Dreamweaver
- Build a registration page
- Build a login page
- Build a page that only authorized users can access
- Securing folders in Coldfusion using Dreamweaver
- Using ColdFusion components in Dreamweaver
- Test, preview, and publish websites
- Troubleshooting
Use Visual Media Queries to view and edit your web pages at different breakpoints corresponding to different screen sizes.
Media Queries is a CSS3 module that helps you design responsive websites by defining different style rules for different devices or media types. Based on these rules, content is rendered to adapt to various conditions, such as, screen sizes, browser window sizes, device sizes and orientation, and resolution.
You can add media queries using the @media rule to your CSS. Or, you can create separate style sheets for different media types and then call them using the following syntax:
<link rel='stylesheet' media='all' href='normal.css' /> <link rel='stylesheet' media='print' href='print.css' /> <link rel='stylesheet' media='screen and (min-width: 701px)' href='medium.css' />
The browser on a device checks the media query and uses the corresponding CSS file to display the web page.
For more information, see this article.
You can add the media queries by adding the relevant code to your HTML or CSS files. In addition, Dreamweaver lets you create and manage media queries easily using:
The basic difference between these two methods is the visual aspect. If you prefer to code and then view the changes in Live view, use the CSS Designer. If you prefer to visualize your page at different breakpoints and simultaneously make design changes, Visual Media Query is a better bet.Visual Media Query bars
Visual Media Query bars are a visual representation of the media queries present in a page. These bars help you visualize your web page at different breakpoints and how different components of your web page reflow in different viewports. While you view your page in different viewports, you can make design changes that are specific to a viewport without affecting the page design in other viewports.
Visual Media Query consists of three bars as horizontal rows, each representing a category of media query:
- Green: Media queries with max-width conditions
- Blue : Media queries with both min-width and max-width conditions
- Purple : Media queries with min-width conditions
The media queries listed in the CSS designer panel are also prefixed with these colors.
Each category can consist of one or more media queries. If a media query condition is not defined in the document, then the corresponding visual media qurey bar, too, will not be displayed. For example, if the document does not contain min-width conditions, then the purple bar is not displayed.
The breakpoint values are indicated on the bars - min-width at the left and max-width at the right of the bar.
A. Breakpoints B. Visual Media Query bars C. Add media query icon D. Scrubber
Hide or show Visual Media Queries
The Visual Media Query bar is visible in Live View by default. To hide the bar, use the Toggle Visual Media Queries bar in the toolbar.
Switch between breakpoints
To view your page in a specific size (breakpoint), click the corresponding media query bar. The document will snap to the breakpoint.
Alternatively, you can drag the scrubber to the required breakpoint.
To resize the view to the size of the Dreamweaver document window, do one of the following actions:
- Double-click anywhere in the grey area at the right of the document where you see the text 'Double Click To Fit Width'. If you don't see the grey area, drag the scrubber to the left.
- Select the Full Width option in the drop-down list at the bottom of the document window.
If you do not see this option, drag the scrubber to decrease the size of the web page.
Edit media queries visually
-
Resize handles appear. For media queries that have both min and max-width values, resize handles appear on both the sides of the bar.
-
Drag the handles to the required size.
The media queries are automatically updated with the new min-width and/or max-width values. A notification is displayed to indicate that the media query was successfully edited. If there are multiple media queries that correspond to the visual media query bar, all the media queries are updated. The number of media queries that were updated is displayed along with the success message.
To undo, press Ctrl+Z (Win) or Cmd+Z (Mac).
Alternatively, you can double-click the breakpoint values to type in the values using your keyboard.
Add new media queries
-
Drag the scrubber along the ruler to the required size.
-
Click .
-
In the pop-up that appears, the max-width option is selected by default. To specify min-width or min-max, select the appropriate option in the drop-down list and select the required units.
Then, select a CSS source in which the media query must be added.
If you choose to create a new CSS file, another pop-up appears. Specify the name and the path of the new CSS file and click OK.
To undo, press Ctrl+Z (Win) or Cmd+Z (Mac).
Delete media queries
-
Right-click the corresponding Visual Media Query bar.
-
Click Delete and then click the media query that you want to delete.
-
Click OK to confirm that you want to delete all the media queries and the associated selectors.
To undo, press Ctrl+Z (Win) or Cmd+Z (Mac).
View the code for media queries
-
Right-click the required Visual Media Query bar and hover your mouse on Go To Code.
A list of all media queries in that particular breakpoint range along with the files in the which they are declared appears.
-
Click the required media query to navigate to the corresponding code in Code View.
If the Code View is not visible, the document is switched to Split view to display the code.