What is the best way to implement responsive html within the Avada theme?

Greetings! Is there a way to apply HTML/CSS code in the Avada theme on WordPress while ensuring it is responsive?

Kindly refer to this image.

https://i.sstatic.net/GMmg7.jpg

Answer №1

To make your CSS work on both screens, include the @media tag in your HTML code!

Answer №2

This is a code snippet.

<style>
div.cities {
    background-color: #ecf0f1;
    color: #000;
     border:3px solid #bdc0c1;
     border-style:dashed; }
.clear {clear: both}
.flex{ display:flex;margin: 20px; padding: 20px 0 0;}
.flex img{
  width: 60px;
  height: 60px;
margin: 0 10px;
}
.flex strong {font: 14px isans-light; color: #4c4b51;}
.flex p {width: 145px; height: 40px;color: #8d8d8d;font: 12px isans-light}


</style>
<div class="cities">

<div class="flex">
  <img  src="wp-content/uploads/2017/01/f-01.png"/>
  <div>
  
  <strong>  Sample text here

</strong>
  <p>Sample text here</p>
  </div>
 <img  src="wp-content/uploads/2017/01/f-02.png"/>
  <div><strong>Sample text here</strong>
    <p> Sample text here</p>
  </div>
  <img  src="wp-content/uploads/2017/01/f-03.png"/>
  <div><strong>Sample text here </strong>
    <p> Sample text here</p>
  </div>
  
  <img  src="wp-content/uploads/2017/01/f-04.png"/>
  <div><strong>Sample text here</strong>
    <p> Sample text here </p>
  </div>
  
  
  
  
  
</div>

</div>

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Unable to update due to outdated response call causing issues

I am currently in the process of updating outdated response calls and have encountered a peculiar issue where the response is not being properly ended. Typically, I would use : res.send(200, {message: 'Location Updated'}); However, this method ...

Discovering the Authentic Page upon Completion of Load using PhantomJS

I am facing an issue while automatically downloading a theme on Wordpress using PhantomJS. The problem arises because the page is not fully evaluated even after it appears to be done loading. When trying to interact with elements on the page, such as clic ...

Enhance the functionality of various textareas by implementing bullets for easier organization and formatting

Is there a way to add bullets to hidden textareas that are created dynamically? Currently, I can add bullets to visible textareas but would like the functionality to extend to newly created ones as well. Additionally, is it possible for these new bullets t ...

Struggling with the display property d-none in Bootstrap

I'm currently attempting to show a segment of my code exclusively on medium-sized screens and larger, while displaying another portion of the code solely on small and extra-small screens through the utilization of Bootstrap. I made use of Bootstrap&ap ...

Executing a function in the view/template with Angular 2+

Whenever a function is called in the view of an Angular component, it seems to be executed repeatedly. A typical example of this scenario can be seen below: nightclub.component.ts import { Component } from '@angular/core'; @Component({ selec ...

evaluating an object against null

When comparing two objects a and b, it is necessary to ensure that one of them is not null. However, deciphering this can be quite chaotic. {} - null => -0 [] - null => 0 1 - null => 1 "1" - null => 1 true - null ...

Handling concurrent requests in DjangoDiscover how Django manages multiple simultaneous requests

Handling multiple requests in a web application can be a challenging task, especially when the server needs to perform complex operations like making API requests and executing database queries. In this post, we will explore how Django can effectively mana ...

"Quotes are essential in Javastript syntax for specifying string values

I need to implement a JavaScript syntax to generate unique URLs for each image. The Robohash website provides random robot images based on different URL endings. I tried the code below, but it seems like ${props.id} is being interpreted as part of the UR ...

hover-triggered keyframe animation

Recently, I've been experimenting with CSS keyframe animation using the code below: .pulse-animation { margin: 50px; display: block; width: 52px; height: 52px; border-radius: 50%; background: #ff8717; cursor: pointer; animation: pul ...

Is there a way to present both Javascript and templates from parallel directories using express?

QUERY: Is there a way to modify the server.js file so that the three.js script in index.html does not display an error message like Cannot GET /node_modules/three/three.js? Code Snippet: index.html <!DOCTYPE html> <html lang="en"> <head&g ...

VueJS form validation does not account for empty inputs in both fields

One of the challenges I'm facing is generating a form with Vue.js using the input fields below: { name: 'first_name', type: 'text', label: 'First Name', placeholder: 'First Name', ...

"Transforming a simple object into an instance of a different type in JavaScript: A step-by-step guide

Having an issue storing a session on disk for local development. The application is asking for an instance of Session to be returned, not an Object function storeCallback(session) { console.log("storeCallback ", session); fs.writeFileSync(&qu ...

Unload pre-loaded JavaScript documents

Two javascript files are included in a popup (simple div) created using ajax. <script type="text/javascript" src="<?php echo JS ?>pm.js"></script> <script type="text/javascript" src="<?php echo JS ?>chat.js"></script> ...

React - the use of nested objects in combination with useState is causing alterations to the initial

After implementing radio buttons to filter data, I noticed that when filtering nested objects, the originalData is being mutated. Consequently, selecting All again does not revert back to the original data. Can anyone explain why both filteredData and orig ...

Issues arising from utilizing Twitter Bootstrap 3.1.x, the box-sizing property, and Revolution Slider

I'm currently working on a PyroCMS theme that is built with Twitter Bootstrap 3.1.x and includes Revolution Slider. However, I've encountered an issue where the property box-sizing: border-box; creates an unwanted grey border as shown in the imag ...

Retrieve the image information from a specified element in the Document Object Model

Is it possible to extract the image data of a DOM element using standard JavaScript or browser extensions? I'm considering scenarios where: Creating an offscreen DOM element Populating it with dynamically styled CSS content Retrieving its image dat ...

Error: Chrome is preventing an AJAX request

Hello everyone, I have been facing an interesting issue with my Ajax request. It seems to work perfectly fine in Internet Explorer, which is quite surprising. However, when I attempt to run the same code in Chrome, I encounter the following error: XMLHt ...

Why does the code require the use of window when the Javascript error object is not functioning properly?

I'm struggling to grasp the distinction between var maxResult = window.max(maxValInt1, maxValInt2); which functions properly, and var maxResult = max(maxValInt1, maxValInt2); which gives an error "object is not a function". Why do I have to inclu ...

(node:45207) UnhandledPromiseRejectionWarning: The server has already sent headers, which caused an error

Currently, I am expanding my knowledge of Node.js through the development of a straightforward code snippet application. The application is designed to include two essential fields, namely title and snippet. However, I am encountering a persistent error me ...

Creating a fresh universal alias or command within a node command line application- How to do it?

I'm feeling uncertain about whether I've articulated this question correctly. Let me clarify with an example. Take a look at this package.json file. https://i.sstatic.net/elO9b.png I'm aiming to have my node app create additional global co ...