Have tried the HTACCESS fixes all the clear this rest start that fixes and still nothing, scripts work in IE, Opera, Chrome but not Firefox....HELP!!!!
<video show controls class="embed-responsive-item">
<source src="uploads\video\<?php echo $rows['File_Attached']; ?>"
type="video/mp4">
</video>
<audio preload="auto" controls>
<source src="uploads\audio\<?php echo $rows['File_Attached']; ?>" >
</audio>
Found the problem to be the path to the file, all other browsers understand upload/video/file.mp4 for example but firefox wanted upload\video\file.mp4
which all other browsers understand as well... note to self remember the correct path.
Related
the html part looks like this:
...
<form action="/upload/select-single/" method="post" enctype="multipart/form-data">
<input type="hidden" name="csrfmiddlewaretoken" value="U3Uh3EAYWXaWEiNaWC3zcCQutQe8hGM53u4BTx810o08t1GwOfIJI2ayHCFQFySw">
<p>
<label for="id_file_field">File field:</label>
<input id="id_file_field" name="file_field" type="file" multiple="" required="">
</p>
<input id="submit" type="submit" value="submit">
</form>
...
the selenium test like this:
...
btn_choose_file = self.browser.find_element_by_id("id_file_field")
# write file path to field
# to check that I really selected the field, I tried btn_choose_file.click() -> and it works
btn_choose_file.send_keys('/path/to/file') # -> THIS is the line which seems to cause the problem
# click submit
self.browser.find_element_by_id("submit").click()
...
unfortunately when the test is executed this error is raised
selenium.common.exceptions.WebDriverException: Message: File not found: /path/to/file
this due to the part where the file path is send to the input element with btn_choose_file.send_keys('/path/to/file')
note: the real '/path/to/file' is the following
/Users/udos/development/trails/processfile/gpx_data/test_data/suite 001 - val poschiavo/Bernina - Le Prese.gpx (the file exists and I copied the path from the IDE)
very odd behaviour. this test was running before, somehow I managed to break it...
any suggestions what the cause could be?
UPDATE downgrading Firefox from version 55.0.2 to 54.0.1 "fixed" the issue.see -> https://stackoverflow.com/a/45753912/420953
One way to work around the issue is to replace all "/" occurances in the filename with "\" ("\\" in python).
This work at least on Windows.
After this bug i installed and used chromewebdriver. Worked like firefox driver and all my tests run smoothly. I suggest you try it at least it worked like a charm for me
this error was due to an update of Firefox to version 55.0.2 (which automatically happened 2 days ago because I have automatic updates configured)
the following geckodriver issue pointed me into this direction
https://github.com/mozilla/geckodriver/issues/659note: probably this issue was reintroduced in 55.0.x...
I then downgraded my Firefox version to 54.0.1 as described in article
https://support.mozilla.org/en-US/kb/install-older-version-of-firefoxnote: make sure to disable automatic updates as described in that article.
with this, the selenium tests are running again.
I use TYPO3 CMS 6.2.14, vhs 2.3.3, Flux 7.2.1 and FluidContent 4.3.1 - my TYPO3 Editor need the opportunity to upload SVG-Images via vhs-ViewHelper. I've made a new FluidTYPO3 Content Element (FCE), but there's no SVG Image visible in frontend. Mmhh?
Flux-FlexForm
<flux:field.file name="imgIcon" allowed="jpg,gif,png,jpeg,svg" uploadFolder="uploads/tx_myext" minItems="0" maxItems="1" size="1" />
...
<v:media.image src="uploads/tx_myext/{imgIcon}" alt="Icon" />
Output
<div class="small-2 columns">
<img alt="Icon" src="" width="" height="">
</div>
Also I use the htaccess entry, but there is no success. Where's my fault? Do I need heightand widthfor this ViewHelper? Aren't vectors availible in vhs?
<IfModule mod_mime.c>
...
AddType image/svg+xml svg svgz
AddEncoding gzip svgz
...
</Ifmodule>
EDIT: I also tried the Fluid ViewHelper, but the SVG Image has height/width = 0:
<f:image src="uploads/tx_myext/{imgIcon}" width="50" height="50" class="xy" alt="Icon" />
EDIT 2: The ImagePath is correct. At Developer Tools I "see" the Image ..
EDIT 3: Oh, I see at my Filemanager (FAL) 0x0 pixels ..
Thanks merec.
Use SVG Images / TYPO3 6.2 with FluidTYPO3
Answer: Use
<img src="{f:uri.image(src: 'uploads/tx_myext/{imgIcon}')}">
instead of
<v:media.image src="uploads/tx_myext/{imgIcon}" alt="Icon" />
// OR
<f:image src="uploads/tx_myext/{imgIcon}" width="50" height="50" class="xy" alt="Icon" />
I found in a streaming site the thing I want to do and I already lost 2 days to understand how they do it. So please analyze the next info and tell me how he does this thing???
Example of what I mean is in this link: http://www.animeforce.org/ds.php?file=AbsoluteDuo/AbsoluteDuo_Ep_01_SUB_ITA.mp4
In development kit we found the direct link of this video: http://www.lacumpa.org/DDL/ANIME/AbsoluteDuo/AbsoluteDuo_Ep_01_SUB_ITA.mp4
<div style="width: 100%; position: relative;" class="html5video lightsoff" id="wtf">
<div class="main-container" id="wtf">
<div class="hero-unit">
<video controls="" preload="metadata" id="video-player">
<source type="video/mp4" src="http://www.lacumpa.org/DDL/ANIME/AbsoluteDuo/AbsoluteDuo_Ep_01_SUB_ITA.mp4"></source>
</video>
</div>
</div>
<div style="text-align: center; padding: 10px 0px 0px 0px; font-size:12pt; font-weight: bold;" class="lightsoffbtn">Modalità Cinema!</div></div>
The second was if you use Download button in the page you access to adfly "they use it to monetize" after skip the adds download start like from a hotlink but if you copy the link from where you download is the same from embedded sourcecode and if you try after stop download to use again direct link, again you are redirected to "Anty Hotlink".
Simplest solution would be a HTTP_REFERER block. If the request for the content does not include the URL of the correct referring page, in it's HTTP HEADER, you block access eg. Using mod_rewrite
RewriteCond %{HTTP_REFERER} !www.somsite.com/some_URI_path
RewriteRule \.(jpg|gif|png)$ - [F,L]
Beyond that you can do things with cookies, e.g again with mod_rewrite
RewriteCond %{HTTP_COOKIE} xxxxxxxxxxxx [NC]
RewriteRule \.(jpg|gif|png)$ - [F,L]
Or if you want to get serious use session based blocks.
I have recently been struggling with setting up my webhost to be used for mercurial repos and also for hgweb. I use nearlyfreespeech.net (NFSN) for hosting.
By default, NFSN has a CGI realm of freebsd72 and restricts you to just CGI, no WGSI or the likes. Originally, NFSN had mercurial 1.6 installed but by following these instructions loosely I was able to get mercurial 2.6 setup. Python 2.6.6 is also installed by default on the host and I have left that as is.
My problem now is that I am not able to load the hgweb.cgi file in my browser. When I run it via SSH on my host it runs fine and output HTML, but in my browser I get a 500 internal server error. The file is executable and CGI is enabled. I am not sure what else there is to check... Does anybody have any advice or experience using hg and hgweb on NFSN?
As suggested in a comment, I have checked the error logs created and found that when I visit the site I get...
[Sun Jun 16 08:22:31 2013] [error] [client 172.17.0.141] CGI ERROR: A system problem prevented your request from being completed.
[Sun Jun 16 08:22:31 2013] [error] [client 172.17.0.141] Premature end of script headers: hgweb.cgi
A bit of searching on that error turns up that it means the script may not be generating the correct headers when run. If I save the output of the script to a file I get the following...
Status: 200 Script output follows
Content-Type: text/html; charset=US-ASCII
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
<head>
<link rel="icon" href="/static/hgicon.png" type="image/png" />
<meta name="robots" content="index, nofollow" />
<link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
<title>Mercurial repositories index</title>
</head>
<body>
<div class="container">
<div class="menu">
<a href="http://mercurial.selenic.com/">
<img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
</div>
<div class="main">
<h2>Mercurial Repositories</h2>
<table class="bigtable">
<tr>
<th>Name</th>
<th>Description</th>
<th>Contact</th>
<th>Last modified</th>
<th> </th>
</tr>
</table>
</div>
</div>
</body>
</html>
I was able to find that the hgweb.cgi script actually required to be set to 755 permissions, setting it to be executable was not enough.
There's a Markdown-to-HTML converter at Pagedown project (JS script).
My question is: how can I adapt this JS script to WSH (Windows Script Host) usage? I need e.g. js script which can be called by WSH command line:
cscript.exe md_to_html.js c:\test\aa.md
I didn't find such page in google.
Create WSF-file named pagedown.wsf with the following script
<job>
<object id="Stream" progid="Adodb.Stream" /> <!-- utf-8 documents support -->
<script language="jscript" src="Markdown.Converter.js" />
<script language="jscript">
Stream.Charset = 'utf-8';
Stream.Open();
Stream.LoadFromFile(WScript.Arguments.Item(0));
var text = Stream.ReadText();
WSH.Echo(new Markdown.Converter().makeHtml(text))
</script>
</job>
and use it with cscript.exe
cscript //Nologo pagedown.wsf input.md > output.html
In case of troubles with ADODB try to download and install it from here.