#StackBounty: #html #ios #css #firefox h2 elements all bunched up on top image on iOS & Firefox

Bounty: 100

On the site Codexr.io I am noticing that while the h2 elements work on any size browser for Chrome, however I am seeing with iOS and Firefox, all of the h2s are on top of one another in one of the main images.

Here’s the HTML:

Collaborative

And the CSS:

#top-area .top-area-text, #top-area .region-top-fifth h2, #top-area .region-top-fifth h2 {
    left: 0;
    text-align: center;
    top: 4em;
    width: 100%;
    color: white;
    font-size: 3em;
    text-shadow:
        -1px -1px 0 #000,  
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
    text-transform: uppercase;
}

#top-area .top-area-text {
    position: absolute;
}

Is there something I’m missing? Why is Chrome working but Firefox and iOS not? Is something malformed?


Get this bounty!!!

#StackBounty: #jquery #html #css #css3 #width How do I get my styled select menu to be 100% width of the parent container in Chrome?

Bounty: 150

I’m creating a form with a text box and a styled select menu (essentially a DIV with other DIVs within it). I would like both items to be the same width, preferably not a fixed pixel width, but rather 100% of the available space. I have

  
*
*
Select Notification Time Above Below

in which I specify 100% width for the text box …

input[type=text] {
  margin-bottom: 20px;
  margin-top: 10px;
  padding: 15px;
  border-radius: 5px;
  border: 1px solid #7ac9b7;
  box-sizing: border-box;
  width: 100%;
  /*  added property  */
}

and then “100%” for the width of the styled DIV menu (done through jQuery). This works great on Firefox — https://jsfiddle.net/yj3cdvfy/3/ , but in Chrome its not looking so aligned. Notice the text of the styled select mneu is wrapping and the text box is exceeding the boundary of the parent container. I thought Chrome was supposed to be the good browser! Anyway, what do I need to do to get things working in Chrome the same way as in Firefox?


Get this bounty!!!

#StackBounty: #javascript #jquery #html #css Transforming Vertical Tab to Accordion

Bounty: 50

I’m trying to turn my vertical tab into an accordion view when the page is less than 480px and back to vertical tab view if it is not. I’ve tried to use @media screen and (min-width: 480px) {} + adding the vertical tab CSS styling but I ended up going no where with it. Then I tried searching a way on how to do this online. I ended up finding some examples but they used different methods on how to accomplish this effect. How can I get this vertical tab transform into an accordion when the screen is less than 480px?

The Link below is an example of the effect I’m going for. (when looking at the example resize the window to see the vertical tab/accordion effect)

Example: https://codepen.io/thejettmiller/pen/hqnua

$(document).ready(function() {


  //----------Select the first tab and div by default

  $('#vertical_tab_nav > ul > li > a').eq(0).addClass("selected");
  $('#vertical_tab_nav > div > article').eq(0).css('display', 'block');


  //---------- This assigns an onclick event to each tab link("a" tag) and passes a parameter to the showHideTab() function

  $('#vertical_tab_nav > ul').click(function(e) {

    if ($(e.target).is("a")) {

      /*Handle Tab Nav*/
      $('#vertical_tab_nav > ul > li > a').removeClass("selected");
      $(e.target).addClass("selected");

      /*Handles Tab Content*/
      var clicked_index = $("a", this).index(e.target);
      $('#vertical_tab_nav > div > article').css('display', 'none');
      $('#vertical_tab_nav > div > article').eq(clicked_index).fadeIn();

    }

    $(this).blur();
    return false;

  });


}); //end ready
    /* if in drawer mode */
    $(".tab_drawer_heading").click(function() {
      
      $(".tab_content").hide();
      var d_activeTab = $(this).attr("rel"); 
      $("#"+d_activeTab).fadeIn();
      
      $(".tab_drawer_heading").removeClass("d_active");
      $(this).addClass("d_active");
      
      $("ul.tabs li").removeClass("active");
      $("ul.tabs li[rel^='"+d_activeTab+"']").addClass("active");
    });
    
body {
  margin: 0px;
  padding: 20px;
  background: #9adde5;
  font-family: arial, sans-serif;
  font-size: 10pt;
  line-height: 15pt;
}


/*---------- vertical tab nav */

#vertical_tab_nav {
  display: block;
  width: 100%;
}

#vertical_tab_nav ul {
  display: block;
  float: left;
  margin: 0px;
  padding: 0px;
  list-style: none;
  overflow: hidden;
  width: 30%;
  border-radius: 10px 0 0 10px;
  background: #555;
}

#vertical_tab_nav li {
  border-bottom: 1px solid #000;
  margin-bottom: 1px;
  text-align: left;
  padding: 0px;
}

#vertical_tab_nav li:last-child {
  margin-bottom: 0px;
  border-bottom: 0px;
}

#vertical_tab_nav li a {
  display: block;
  font-size: 14pt;
  color: #fff;
  text-decoration: none;
  padding: 7%;
  background: #57cac9;
  background: -webkit-linear-gradient(top, #444, #333);
  background: -moz-linear-gradient(top, #444, #333);
}

#vertical_tab_nav li a.selected {
  background: #fff;
  color: #000;
}

#vertical_tab_nav div {
  display: block;
  float: left;
  background: #fff;
  background: #fff;
  width: 64%;
  min-height: 500px;
  padding: 10px 3% 3% 3%;
  border-radius: 0 10px 10px 0;
}

#vertical_tab_nav div article {
  display: none;
  margin: 0px;
  color: #555;
}

#vertical_tab_nav div article p {
  margin: 0px 0px 20px 0px;
}

.tab_drawer_heading {
  display: none;
}

@media screen and (max-width: 781px) {
  ul.tabs {
    display: none;
  }
  .tab_container {
    display: block;
    margin: 0 auto;
    width: 95%;
    border-top: none;
    border-radius: 0;
    box-shadow: 0px 0px 10px black;
  }
  .tab_drawer_heading {
    background-color: #ccc;
    color: #000;
    margin: 0;
    padding: 5px 20px;
    display: block;
    cursor: pointer;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    text-align: center;
    &:hover {
      background: #ccc;
    }
  }
  .d_active {
    background: #fff;
  }
}
https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js


<section id="vertical_tab_nav">

  <ul class="tabs">
    <li><a href="index.html">Tab One</a></li>
    <li class="selected"><a href="index.html">Tab Two</a></li>
    <li><a href="index.html">Tab Three</a></li>
    <li><a href="index.html">Tab Four</a></li>
  </ul>

  

Tab Content One

Adult education is essential for Democracy of India. The number of grown up illiterates is great. All college and senior School students should come forward to visit villages in the summer vacation. Each one will teach one there. This will remove illiteracy and strengthen our democracy. I happened to see a one day cricket match between Pakistan and Australia at Wankhade Stadium, Mumbai. I went for a fun. But I witnessed a horrible sight. Two thousand ticketless cricket fans gate crashed. There was a stampede. Three persons died and twenty were injured. Administration was responsible for it.

Tab Content Two

City Anti-pollution Drive demands certain steps from all the citizens of ABC city. All house-holders should pack the waste in a plastic bag and put the bag in front of their house. The bag will be replaced with an empty bag by the Municipal van every morning. They should maintain the cleanliness of the city. This will make the city pollution free. My visit to a slum area after the rainy season was a sad affair. The pits were still full of rain water. There was mud all around. The polluted water had caused various diseases. There was no home without a sick person. Small children suffered from stomach troubles. The government should immediately rush to the help of the sufferers in the slum area.

Tab Content Three

I saw a man climbing down a water pipe. He had a knife in his hand. I hit his hand with a brick. He fell down on the ground and I jumped upon him. Soon others reached there and we handed him over to the police. A tragedy took place yesterday when a Matador fell into a canal. The driver of the Matador tried to save an auto-rickshaw and lost control on the vehicle. About fifty students were travelling in it. The people from the nearby villages saved twenty-seven students. The dead bodies of the drowned were recovered. It was a very painful sight.

Tab Content Four

City life is full of fun. There are parks and picnic spots to visit. We have cinema halls to see movies. We have electricity which runs our factories, light and cools our home and helps us in seeing T.V. There are all type of amenities like water, health check up and transport. Sometimes circus shows and magic shows entertain the city people. I was lucky to escape death by a few seconds.' A bomb blasted in the compartment of Nilanchal Express. The overcrowded compartment made me to get down. Anyhow the loss was great. About ten people died and many got injured. It was the job of a terrorist. The government should intensify searching operations in trains.1
</section>


Get this bounty!!!

#StackBounty: #external-files #html #shortcut Run the JavaScript code on a web page from the shortcut in my file?

Bounty: 50

MWE

documentclass[a4paper,11pt]{article}
usepackage{color}
usepackage[hyphens]{url}
usepackage[colorlinks=true,linkcolor=blue]{hyperref}
begin{document}
href{javascript}{DownloadSubmit(%20'146'%20,%20'fx991esplus.pdf'%20,%20'1'%20}
%href{https://edu.casio.com/education/activity/fx991esplus.pdf}{fx991esplus.pdf}
end{document}

enter image description here

How do I direct a JavaScript shortcut like this from within a file?

javascript:DownloadSubmit(%20'146'%20,%20'fx991esplus.pdf'%20,%20'1'%20)

Is something like this possible?

Related: https://edu.casio.com/education/activity/

Added image:

enter image description here


Get this bounty!!!

#StackBounty: #open-source #javascript #html #table #responsive-design Responsive JavaScript table to load 20k records in 2 or 3 seconds

Bounty: 50

I am looking for a responsive JavaScript table which loads and handles atleast 20k records within 2 or 3 seconds and have many options:

  • CSV
  • Copy to clipboard
  • Export Excel, PDF, text, PNG, Word, JSON
  • Visible columns

It must be open source.

Here is the ones I have found:

  • Swimlane – It’s not active as of now. No updates for a long time.
  • Angular UI Grid – Uses ng:repeat which slows down the rendering.
  • Slick Grid – It’s not active as of now. No updates for a long time.
  • Datatables


Get this bounty!!!

#StackBounty: #2013 #javascript #development #css #html Can i rearrange my Key Filter for a wiki page to appears on the top of the page…

Bounty: 50

I am working on an enterprise wiki site collection inside my sharepoint server 2013 on-premises. and inside this site collection i have enabled the Metadata navigation and filter site feature:-

enter image description here

Then i defined the following fields to be used inside the Key filters:-

enter image description here

so the result i got is that when i navigate to the wiki pages library, i will get the key filters fields on the left hand side of the screen as follow:-

enter image description here

now our customer did not like this look and feel. and they asked us to made the key filters columns to be displayed in a grid on the top of the page. now i find this list view web part which suppose to work well https://splistviewfilter.codeplex.com/ . but the problem i got with this list view web part is that the filter will work well on the first click, but when i do a paging the filter setting will be ignored.

so my question is that can i using css/javascript to realign the built-in key filters to be show as follow:-

  1. in a grid view, 3 columns per row, instead of being displayed under each other
  2. show the key filter at the top of the page instead of being displayed at the left hand side of the page ?

something such as :-

enter image description here


Get this bounty!!!

#StackBounty: #html #css #xml #ms-word #pandoc from HTML <figure> and <figcaption> to Microsoft Word

Bounty: 50

I have an HTML with thefigure, img and figcaption tags and I would like to get them converted to a Microsoft Word document`.

The image referred by img should be inserted in the Word document and the figcaption should be converted to its caption (also keeping the figure number).

I have tried to open the html with Word 2013 but the figcaption is not converted as the figure caption but it is just a simple text below the image.

Is there any minimum working sample to get it done? I had a look at https://en.wikipedia.org/wiki/Microsoft_Office_XML_formats#Word_XML_Format_example but it is too verbose to grab just an Hello world sample.

figure .image {
    width: 100%;
}

figure {
    text-align: center;
    display: table;
    max-width: 30%; /* demo; set some amount (px or %) if you can */
    margin: 10px auto; /* not needed unless you want centered */
}
article {
  counter-reset: figures;
}

figure {
  counter-increment: figures;
}

figcaption:before {
  content: "Fig. " counter(figures) " - "; /* For I18n support; use data-counter-string. */
}
<figure>
<p><img class="image" src="https://upload.wikimedia.org/wikipedia/commons/c/ca/Matterhorn002.jpg"></p>
<figcaption>Il monte Cervino.</figcaption>
</figure>

<figure>
<p><img class="image" src="https://upload.wikimedia.org/wikipedia/commons/2/26/Banner_clouds.jpg"></p>
<figcaption>La nuvola che spesso รจ vicino alla vetta.</figcaption>
</figure>

I tried with pandoc

pandoc -f html -t docx -o hello.docx hello.html

but with no luck, as you can see the “Fig. 1” and “Fig. 2” is missing:

enter image description here

My pandoc is:

c:temp>.pandoc.exe -v
pandoc.exe 1.19.2.1
Compiled with pandoc-types 1.17.0.4, texmath 0.9, skylighting 0.1.1.4
Default user data directory: C:UsersaleAppDataRoamingpandoc
Copyright (C) 2006-2016 John MacFarlane
Web:  http://pandoc.org
This is free software; see the source for copying conditions.
There is no warranty, not even for merchantability or fitness
for a particular purpose.


Get this bounty!!!

#StackBounty: #javascript #html #internet-explorer #jsf onchange event and programmatic input value change conflict on IE

Bounty: 50

I’ve noticed that in different versions of Internet Explorer the onchange event is not captured when the value of an input is altered by a js function, behavior that does not occur with other browsers such as Mozilla or Chrome.

Investigating a little I found that the correct operation of onchange in IE is not guaranteed when the value is altered by js:

Example (test on IE):

function onchangeRequest(){
  console.log('onchange fired');
}

function changeValue (input){
        input.value +=  "add"
 }
<h4> focus lost doesnt invoke onchangeRequest() </h4>

<input id="valueInput"  onkeyup="changeValue(this);" onchange="onchangeRequest();" />

<h4> focus lost invokes onchangeRequest() </h4>

<input id="valueInput" onchange="onchangeRequest();" />

I have not found a convincing explanation of the reasons why IE does not solve those situations correctly and although there are alternatives to get the same behavior, such as implementing onchange withonfocs and onblur saving the previous value of the input and Checking if there were changes, I would like to know the reasons why this behavior occurs.


Get this bounty!!!

#StackBounty: #javascript #jquery #html #actionscript-3 #flash reload embedded swf in html page in IE

Bounty: 50

I have a swf file embedded in a html page. I want to reload the swf file without refreshing the page.

There is a same problem asked here: reload/ reset embedded swf on click

And I tried the accepted answer and it works in chrome:

var obj = $("object#flash_99674493");
obj.html(obj.html());

But it seems it doesn’t work in IE. How to make it work in IE?


Get this bounty!!!

#StackBounty: #html #r #shiny shiny, timevis and html templates

Bounty: 100

i’m having a problem displaying a timevis in an html block in shiny.

the following code is the base example which works:

library(shiny)
library(timevis)

data <- data.frame(
  id      = 1:4,
  content = c("Item one", "Item two",
              "Ranged item", "Item four"),
  start   = c("2016-01-10", "2016-01-11",
              "2016-01-20", "2016-02-14 15:00:00"),
  end     = c(NA, NA, "2016-02-04", NA)
)

ui <- bootstrapPage(
  timevisOutput("timeline")
)

server <- function(input, output, session) {
  output$timeline <- renderTimevis({
    timevis(data)
  })
}

shinyApp(ui = ui, server = server)

however if i use an html template and try to display the content this does not appear. here is sample code

   library(shiny)
    library(timevis)

ui <- bootstrapPage(
            tags$div(id="page-content-wrapper", 
                    timevisOutput("timeline")
                    )
)

server <- function(input, output, session) {
      output$timeline <- renderTimevis({
      timevis(data)
    })



  }

  shinyApp(ui = ui, server = server)

and the html containing the reference

any idea why this happens? am i missing something? (i.e. appropriate inclusion of js libs in either the app’s header or html file?) if anyone has a working example with htmlwidgets, that could be an alternative too, but i cannot get anything to work at the moment

suggestions very welcome! thanks


Get this bounty!!!