Welcome to the Invelos forums. Please read the forum rules before posting.

Read access to our public forums is open to everyone. To post messages, a free registration is required.

If you have an Invelos account, sign in to post.

    Invelos Forums->DVD Profiler: Layouts and Reports Page: 1  Previous   Next
Trailer (again *sigh*)
Author Message
DVD Profiler Desktop and Mobile RegistrantFingerlakes Dave
Registered: April 6, 2007
United States Posts: 464
Posted:
PM this userView this user's DVD collectionDirect link to this postReply with quote
OK, I get the concept.  I just can't get ANY code I've found in the foorums to work. Period .
And java script is so far out of my depth....

I think the issue is in the local file path.  It doesn't matter if I use // or \\ or / or \.     

Path is: F:\Documents and Settings\Dad.HOME\My Documents\DVD Profiler\Trailers\

  The closest I have come to getting anything to work is the DVD Disk loader plugiin.  The best I can manage there is to get the directory to open and show the file. File does not load in a player. 

Any help appreciated.


Code tried (and only a small sample):

++++++++++++++++++
<html>
<!-- Created on: 8/18/2009 -->
<script language="JavaScript">
last_watch_on = "<DP NAME="LAST_WATCHED_ON">";

if ( last_watch_on.length != 0 ){
document.write("Last watched: "  + last_watch_on);
}
</script>

<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="false">
//-->
</SCRIPT>

<SCRIPT language=javascript>
window.onload = window_onload;
function window_onload() {
  var i;
  myloop: for (i = 0; i < DP_Tags.length; i++) {
    switch (DP_Tags[i]) {
      case "ztrailer/WMV":
        idPlay.href = "F://Documents and Settings//Dad.HOME//My Documents//DVD Profiler//Trailers//" + DP_CollectionNumber + ".wmv";
        break myloop;
      case "ztrailer/MOV":
        idPlay.href ="F:\Documents and Settings\Dad.HOME\My Documents\DVD Profiler\Trailers" + DP_CollectionNumber + ".mov";
        break myloop;
      case "ztrailer/VOB":
        idPlay.href = "F:\Trailers\\" + DP_CollectionNumber + ".vob";
        break myloop;
      case "ztrailer/mpg":
        idPlay.href = "F:\\Trailers\\" + DP_CollectionNumber + ".mpg";
        break myloop;
    case "ztrailer/flv":
        idPlay.href = "//Trailers//" + DP_CollectionNumber + ".flv";
        break myloop;
    }
  }
  if (i >= DP_Tags.length) {
    // Remove link if there is no trailer tag
    idPlay.removeNode(true);
  }
}
</SCRIPT>


<head>
  <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
  <title></title>
  <meta name="description" content="">
  <meta name="keywords" content="">
  <meta name="author" content="Unregistered User">
  <meta name="generator" content="AceHTML Freeware">


<DP NAME="LAYERS" Dual="** DUAL LAYER **" Single="">
<BR><BR>

<B><DP NAME="TITLE"></B>
<BR><BR>

<DP NAME="PURCHDATE" Prefix="Added- ">
<BR><BR>

<DP NAME="DISCS" SubDivider=" - " ShowDescriptions="true" Divider="<BR>"  ShowSlots="true" ShowLocations="true">
<BR><BR>

<A id=idPlay href="#">Play Trailer</A>
<BR><BR>





</BODY>
</HTML>
+++++++++++++++++++++++++++++++++
Tags made, child tags exist, boxes checked.

<HTML>
<HEAD>

<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="False">
//-->
</SCRIPT>

<SCRIPT language=javascript>
window.onload = window_onload;
function window_onload() {
  var i;
  myloop: for (i = 0; i < DP_Tags.length; i++) {
    switch (DP_Tags[i]) {
      case "Trailer/wmv":
        idPlay.href ="F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\" + DP_CollectionNumber + ".wmv";
        break myloop;
      case "Trailer/mov":
        idPlay.href = "F://Documents and Settings//Dad.HOME//My Documents//DVD Profiler//Trailers//"  + DP_CollectionNumber + ".mov";
        break myloop;
      case "Trailer/vob":
        idPlay.href = "F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\" + DP_CollectionNumber + ".vob";
        break myloop;
    }
  }
  if (i >= DP_Tags.length) {
    idPlay.removeNode(true);
  }
}
</SCRIPT>

</HEAD>
<BODY>

<A id=idPlay href="#">Play Trailer</A>

</BODY>
</HTML>
++++++++++++++++++++++++++++
<HTML>
<HEAD>

<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="False">
//-->
</SCRIPT>

</HEAD>
<BODY>
<SCRIPT>
document.write('<OBJECT id="VIDEO" style="position:absolute; left:0;top:0;" width="640" height="480" CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6">')
document.write('<PARAM NAME="URL" VALUE="F://Documents and Settings//Dad.HOME//My Documents//DVD Profiler//Trailers//" + DP_CollectionNumber + '.mov"><PARAM NAME="AutoStart" VALUE="False">')
document.write('<PARAM name="uiMode" value="mini"><PARAM name="PlayCount" value="1"></OBJECT>')
</SCRIPT>
</BODY>
</HTML>
+++++++++++

end
DVD Profiler Desktop and Mobile Registrantmediadogg
Aim high. Ride the wind.
Registered: March 18, 2007
Reputation: Highest Rating
United States Posts: 6,461
Posted:
PM this userVisit this user's homepageDirect link to this postReply with quote
Try this for the tag method.

I fixed a copuple of syntax errors and put in one example of a path for ztrailer/WMV that works on my system. Remember, in order for the trailers to load, you have to make sure the File Associations are set correctly. This is also true for LoadDVD. Yes, you must use "\\" for each "\" in the pathname. This means that if you use a network server, then the "\\" should be changed to "\\\\". You have lots of pathname errors in your examples. Hopefully it is clear to you how to fix those now.

<html>
<!-- Created on: 8/18/2009 -->
<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="false">
//-->

if ( DP_LastWatched.length != 0 ){
document.write("Last watched: "  + DP_LastWatched);
}
window.onload = window_onload;
function window_onload() {
  var i;
  myloop: for (i = 0; i < DP_Tags.length; i++) {
    switch (DP_Tags[i]) {
      case "ztrailer/WMV":
        idPlay.href = "c:\\Documents\\user guide.pdf";
        break myloop;
      case "ztrailer/MOV":
        idPlay.href ="F:\Documents and Settings\Dad.HOME\My Documents\DVD Profiler\Trailers" + DP_CollectionNumber + ".mov";
        break myloop;
      case "ztrailer/VOB":
        idPlay.href = "F:\Trailers\\" + DP_CollectionNumber + ".vob";
        break myloop;
      case "ztrailer/mpg":
        idPlay.href = "F:\\Trailers\\" + DP_CollectionNumber + ".mpg";
        break myloop;
    case "ztrailer/flv":
        idPlay.href = "//Trailers//" + DP_CollectionNumber + ".flv";
        break myloop;
    }
  }
  if (i >= DP_Tags.length) {
    // Remove link if there is no trailer tag
    idPlay.removeNode(true);
  }
}
</SCRIPT>


<head>
  <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
  <title></title>
  <meta name="description" content="">
  <meta name="keywords" content="">
  <meta name="author" content="Unregistered User">
  <meta name="generator" content="AceHTML Freeware">

<DP NAME="LAYERS" Dual="** DUAL LAYER **" Single="">
<BR><BR>

<B><DP NAME="TITLE"></B>
<BR><BR>

<DP NAME="PURCHDATE" Prefix="Added- ">
<BR><BR>

<DP NAME="DISCS" SubDivider=" - " ShowDescriptions="true" Divider="<BR>"  ShowSlots="true" ShowLocations="true">
<BR><BR>

<A id=idPlay href="#">Play Trailer</A>
<BR><BR>

</BODY>
</HTML>
Thanks for your support.
Free Plugins available here.
Advanced plugins available here.
Hey, new product!!! BDPFrog.
 Last edited: by mediadogg
DVD Profiler Desktop and Mobile Registrantmediadogg
Aim high. Ride the wind.
Registered: March 18, 2007
Reputation: Highest Rating
United States Posts: 6,461
Posted:
PM this userVisit this user's homepageDirect link to this postReply with quote
To fix the embedded viewer:

(1) change the single quote in front of .mov to a double quote, i.e., ".mov" instead of '.mov"

(2) Fix the pathname by using "\\" instead of "//"

(3) Enjoy.

I found a couple of glitches that should get you going, but trust me, there are some true wizards, like the guys who made the original scripts, that will come along shortly that can help you get to new levels, if what I have done is not sufficient.
Thanks for your support.
Free Plugins available here.
Advanced plugins available here.
Hey, new product!!! BDPFrog.
 Last edited: by mediadogg
DVD Profiler Desktop and Mobile RegistrantFingerlakes Dave
Registered: April 6, 2007
United States Posts: 464
Posted:
PM this userView this user's DVD collectionDirect link to this postReply with quote
Quoting mediadogg:
Quote:
To fix the embedded viewer:

(1) change the single quote in front of .mov to a double quote, i.e., ".mov" instead of '.mov"

(2) Fix the pathname by using "\\" instead of "//"

(3) Enjoy.

I found a couple of glitches that should get you going, but trust me, there are some true wizards, like the guys who made the original scripts, that will come along shortly that can help you get to new levels, if what I have done is not sufficient.


Hi.
Thanks for the effort.  I'm still not sure what I am doing wrong. (Which is why I put direct trailer support in as a feature request for the gallery).
DVD entry has a Tag of Trailer, and child tag of mov. Both checked.

Here's what I currently have (Window pops up with a link, click or double click link, no joy  ):

<html>
<!-- Created on: 8/18/2009 -->
<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="false">
//-->

if ( DP_LastWatched.length != 0 ){
document.write("Last watched: "  + DP_LastWatched);
}
window.onload = window_onload;
function window_onload() {
  var i;
  myloop: for (i = 0; i < DP_Tags.length; i++) {
    switch (DP_Tags[i]) {
      case "ztrailer/WMV":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".wmv";
        break myloop;
      case "ztrailer/MOV":
        idPlay.href ="F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".mov";
        break myloop;
      case "ztrailer/VOB":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".vob";
        break myloop;
      case "ztrailer/mpg":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".mpg";
        break myloop;
    case "ztrailer/flv":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers"" + DP_CollectionNumber + ".flv";
        break myloop;
    }
  }
  if (i >= DP_Tags.length) {
    // Remove link if there is no trailer tag
    idPlay.removeNode(true);
  }
}
</SCRIPT>


<head>
  <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
  <title></title>
  <meta name="description" content="">
  <meta name="keywords" content="">
  <meta name="author" content="Unregistered User">
  <meta name="generator" content="AceHTML Freeware">

<DP NAME="LAYERS" Dual="** DUAL LAYER **" Single="">
<BR><BR>

<B><DP NAME="TITLE"></B>
<BR><BR>

<DP NAME="PURCHDATE" Prefix="Added- ">
<BR><BR>

<DP NAME="DISCS" SubDivider=" - " ShowDescriptions="true" Divider="<BR>"  ShowSlots="true" ShowLocations="true">
<BR><BR>

<A id=idPlay href="#">Play Trailer</A>
<BR><BR>

</BODY>
</HTML>

ANY and All help appreciated!
DVD Profiler Unlimited RegistrantFredLooks
phpDVDProfilerDude D5/7/2
Registered: March 13, 2007
Canada Posts: 350
Posted:
PM this userEmail this userVisit this user's homepageView this user's DVD collectionDirect link to this postReply with quote
The Dad.HOME part of each of those file paths is preceeded by a single \ when I think you want a double \\

Are these trailers in a directory named trailers? or are the files in a directory named DVD Profiler?  If they are in a directory named trailers, then you nead a trailing \\ after Trailers in your filepaths ...
-fred
DVD Profiler Desktop and Mobile RegistrantFingerlakes Dave
Registered: April 6, 2007
United States Posts: 464
Posted:
PM this userView this user's DVD collectionDirect link to this postReply with quote
Quoting FredLooks:
Quote:
The Dad.HOME part of each of those file paths is preceeded by a single \ when I think you want a double \\

Are these trailers in a directory named trailers? or are the files in a directory named DVD Profiler?  If they are in a directory named trailers, then you nead a trailing \\ after Trailers in your filepaths ...


  I made the changes, now I don't even have a link to click....

  idPlay.href ="F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\" + DP_CollectionNumber + ".mov";
        break myloop;

Zero result.
DVD Profiler Desktop and Mobile Registrantmediadogg
Aim high. Ride the wind.
Registered: March 18, 2007
Reputation: Highest Rating
United States Posts: 6,461
Posted:
PM this userVisit this user's homepageDirect link to this postReply with quote
Quoting Fingerlakes Dave:
Quote:
Quoting FredLooks:
Quote:
The Dad.HOME part of each of those file paths is preceeded by a single \ when I think you want a double \\

Are these trailers in a directory named trailers? or are the files in a directory named DVD Profiler?  If they are in a directory named trailers, then you nead a trailing \\ after Trailers in your filepaths ...


  I made the changes, now I don't even have a link to click....

  idPlay.href ="F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\" + DP_CollectionNumber + ".mov";
        break myloop;

Zero result.

The changes I made to your scripts work on my system. You are clearly still making errors that you are not recognizing. I am not confident that you understand the path structure of your files. Nothing will work until you get that correct, and set up file associations properly.

Why don't you just make a simple test HTML window that simply displays the path (using document.write), then cut and paste that path into a web browser and see what happens. Your errors will immediately become apparent. Try working up to the big picture, a step at a time. You are trying to do the whole thing. I'm suspecting that some details that you are not aware are imporatnt and not telling us, are causing the problem.
Thanks for your support.
Free Plugins available here.
Advanced plugins available here.
Hey, new product!!! BDPFrog.
 Last edited: by mediadogg
DVD Profiler Desktop and Mobile RegistrantFingerlakes Dave
Registered: April 6, 2007
United States Posts: 464
Posted:
PM this userView this user's DVD collectionDirect link to this postReply with quote
Quoting mediadogg:
Quote:
Quoting Fingerlakes Dave:
Quote:
Quoting FredLooks:
Quote:
The Dad.HOME part of each of those file paths is preceeded by a single \ when I think you want a double \\

Are these trailers in a directory named trailers? or are the files in a directory named DVD Profiler?  If they are in a directory named trailers, then you nead a trailing \\ after Trailers in your filepaths ...


  I made the changes, now I don't even have a link to click....

  idPlay.href ="F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\" + DP_CollectionNumber + ".mov";
        break myloop;

Zero result.


The changes I made to your scripts work on my system. You are clearly still making errors that you are not recognizing. I am not confident that you understand the path structure of your files. Nothing will work until you get that correct, and set up file associations properly.

Why don't you just make a simple test HTML window that simply displays the path (using document.write), then cut and paste that path into a web browser and see what happens. Your errors will immediately become apparent. Try working up to the big picture, a step at a time. You are trying to do the whole thing. I'm suspecting that some details that you are not aware are imporatnt and not telling us, are causing the problem.


1) What is document write?  Can't use what I don't know about.

2) My path is directly from Windows Explorer.  Either copied from the "address bar" or from right click on file, properties, highlight path.  (Both paths match, btw)

F:\\Documents and Settings\\Dad.HOME\\My Documents\\DVD Profiler\\Trailers\\ is the path, as you recommended, except when I use ...Trailers\\, there is no link in the window, when I don't there is.

Either way, zero result.

Am I supposed to be saving the htm to a file named something?
DVD Profiler Desktop and Mobile RegistrantMarEll
Registered: June 9, 2007
United Kingdom Posts: 1,208
Posted:
PM this userView this user's DVD collectionDirect link to this postReply with quote
Quoting Fingerlakes Dave:
Quote:

[...]
Hi.
Thanks for the effort.  I'm still not sure what I am doing wrong. (Which is why I put direct trailer support in as a feature request for the gallery).
DVD entry has a Tag of Trailer, and child tag of mov. Both checked.

Here's what I currently have (Window pops up with a link, click or double click link, no joy  ):

<html>
<!-- Created on: 8/18/2009 -->
<SCRIPT TYPE="text/javascript">
<!--
<DP NAME="HEADER_VARS" Language="JavaScript" Comments="True" IncludeCast="False" IncludeCrew="false">
//-->

if ( DP_LastWatched.length != 0 ){
document.write("Last watched: "  + DP_LastWatched);
}
window.onload = window_onload;
function window_onload() {
  var i;
  myloop: for (i = 0; i < DP_Tags.length; i++) {
    switch (DP_Tags[i]) {
      case "ztrailer/WMV":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".wmv";
        break myloop;
      case "ztrailer/MOV":
        idPlay.href ="F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".mov";
        break myloop;
      case "ztrailer/VOB":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".vob";
        break myloop;
      case "ztrailer/mpg":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers" + DP_CollectionNumber + ".mpg";
        break myloop;
    case "ztrailer/flv":
        idPlay.href = "F:\\Documents and Settings\Dad.HOME\\My Documents\\DVD Profiler\\Trailers"" + DP_CollectionNumber + ".flv";
        break myloop;
    }
  }
  if (i >= DP_Tags.length) {
    // Remove link if there is no trailer tag
    idPlay.removeNode(true);
  }
}
</SCRIPT>


<head>
  <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
  <title></title>
  <meta name="description" content="">
  <meta name="keywords" content="">
  <meta name="author" content="Unregistered User">
  <meta name="generator" content="AceHTML Freeware">

<DP NAME="LAYERS" Dual="** DUAL LAYER **" Single="">
<BR><BR>

<B><DP NAME="TITLE"></B>
<BR><BR>

<DP NAME="PURCHDATE" Prefix="Added- ">
<BR><BR>

<DP NAME="DISCS" SubDivider=" - " ShowDescriptions="true" Divider="<BR>"  ShowSlots="true" ShowLocations="true">
<BR><BR>

<A id=idPlay href="#">Play Trailer</A>
<BR><BR>

</BODY>
</HTML>

ANY and All help appreciated!


Your tags and your code don't match for a start.  Your tag needs to be called ztrailer with a child tag called MOV .  This may be case sensitive so make it the same case just in case.
    Invelos Forums->DVD Profiler: Layouts and Reports Page: 1  Previous   Next