Some Questitions about Object Embed

Discussion in 'ASP .Net' started by Alois_Mair, Feb 19, 2008.

  1. Alois_Mair

    Alois_Mair Guest

    Hello @ll!
    i just have a questition: i am actually working on my own video comunity web
    site. i already have some nice videos online. For this i want to give my
    Comunity an embed link to embed the videos stored on my webhost to their own
    sites like youtube...

    actually this embed looks like this:

    <object width="425" height="355">
    <param name="movie" value="player.swf?file=movie.flv"></param>
    <param name="wmode" value="transparent"></param>
    <embed src="player.swf?file=movie.flv" type="application/x-shockwave-flash"
    wmode="transparent" width="425" height="355">
    </embed>
    </object>

    but i am not happy with this embed code because the user knows, where the
    player is located also where the file is being stored. With this link i also
    have no possiblity to count the video (the counter is stored in mssql)

    How can i use an embed link like youtube which looks like this:
    <object width="425" height="355">
    <param name="movie" value="movie.aspx?file=movie.flv"></param>
    <param name="wmode" value="transparent"></param>
    <embed src="movie.aspx?file=movie.flv" type="application/x-shockwave-flash"
    wmode="transparent" width="425" height="355">
    </embed>
    </object>

    i want to create an aspx file, which i can use in the embed above. How can i
    do this without using any Flash Streaming Addins?
    cheers Alois
    Alois_Mair, Feb 19, 2008
    #1
    1. Advertising

  2. You are on the right track. What seems to be a prblem though?

    Just make movie.aspx that will do what you want to do with counter and user
    Response.WriteFile.

    you might need to set correct content type though.
    Use fidler tool (google it) to see what to set ContentType to when returning
    ..flv file

    George.



    "Alois_Mair" <> wrote in message
    news:%23%...
    > Hello @ll!
    > i just have a questition: i am actually working on my own video comunity
    > web site. i already have some nice videos online. For this i want to give
    > my Comunity an embed link to embed the videos stored on my webhost to
    > their own sites like youtube...
    >
    > actually this embed looks like this:
    >
    > <object width="425" height="355">
    > <param name="movie" value="player.swf?file=movie.flv"></param>
    > <param name="wmode" value="transparent"></param>
    > <embed src="player.swf?file=movie.flv"
    > type="application/x-shockwave-flash" wmode="transparent" width="425"
    > height="355">
    > </embed>
    > </object>
    >
    > but i am not happy with this embed code because the user knows, where the
    > player is located also where the file is being stored. With this link i
    > also have no possiblity to count the video (the counter is stored in
    > mssql)
    >
    > How can i use an embed link like youtube which looks like this:
    > <object width="425" height="355">
    > <param name="movie" value="movie.aspx?file=movie.flv"></param>
    > <param name="wmode" value="transparent"></param>
    > <embed src="movie.aspx?file=movie.flv"
    > type="application/x-shockwave-flash" wmode="transparent" width="425"
    > height="355">
    > </embed>
    > </object>
    >
    > i want to create an aspx file, which i can use in the embed above. How can
    > i do this without using any Flash Streaming Addins?
    > cheers Alois
    >
    George Ter-Saakov, Feb 19, 2008
    #2
    1. Advertising

  3. Alois_Mair

    Alois_Mair Guest

    Hi George,
    thank you for your reply, i already have the aspx file with the following
    code:

    Response.Clear()
    ' set the content type to SWF
    Response.ContentType = "application/x-shockwave-flash"
    ' add content type header
    Response.AddHeader("Content-Type", "application/x-shockwave-flash")
    ' set the content disposition
    Response.AddHeader("Content-Disposition",
    "inline;filename=player.swf?file=movie.flv")
    ' write the buffer with swf file to the output
    Response.End()

    this doesn't work?
    thank you, Alois

    "George Ter-Saakov" <> schrieb im Newsbeitrag
    news:%...
    > You are on the right track. What seems to be a prblem though?
    >
    > Just make movie.aspx that will do what you want to do with counter and
    > user Response.WriteFile.
    >
    > you might need to set correct content type though.
    > Use fidler tool (google it) to see what to set ContentType to when
    > returning .flv file
    >
    > George.
    >
    >
    >
    > "Alois_Mair" <> wrote in message
    > news:%23%...
    >> Hello @ll!
    >> i just have a questition: i am actually working on my own video comunity
    >> web site. i already have some nice videos online. For this i want to give
    >> my Comunity an embed link to embed the videos stored on my webhost to
    >> their own sites like youtube...
    >>
    >> actually this embed looks like this:
    >>
    >> <object width="425" height="355">
    >> <param name="movie" value="player.swf?file=movie.flv"></param>
    >> <param name="wmode" value="transparent"></param>
    >> <embed src="player.swf?file=movie.flv"
    >> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >> height="355">
    >> </embed>
    >> </object>
    >>
    >> but i am not happy with this embed code because the user knows, where the
    >> player is located also where the file is being stored. With this link i
    >> also have no possiblity to count the video (the counter is stored in
    >> mssql)
    >>
    >> How can i use an embed link like youtube which looks like this:
    >> <object width="425" height="355">
    >> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >> <param name="wmode" value="transparent"></param>
    >> <embed src="movie.aspx?file=movie.flv"
    >> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >> height="355">
    >> </embed>
    >> </object>
    >>
    >> i want to create an aspx file, which i can use in the embed above. How
    >> can i do this without using any Flash Streaming Addins?
    >> cheers Alois
    >>

    >
    >
    Alois_Mair, Feb 19, 2008
    #3
  4. I do not see the actual line that outputs file to browser.
    Response.WriteFile
    Can it be a reason so it does not work?

    George.


    "Alois_Mair" <> wrote in message
    news:...
    > Hi George,
    > thank you for your reply, i already have the aspx file with the following
    > code:
    >
    > Response.Clear()
    > ' set the content type to SWF
    > Response.ContentType = "application/x-shockwave-flash"
    > ' add content type header
    > Response.AddHeader("Content-Type", "application/x-shockwave-flash")
    > ' set the content disposition
    > Response.AddHeader("Content-Disposition",
    > "inline;filename=player.swf?file=movie.flv")
    > ' write the buffer with swf file to the output
    > Response.End()
    >
    > this doesn't work?
    > thank you, Alois
    >
    > "George Ter-Saakov" <> schrieb im Newsbeitrag
    > news:%...
    >> You are on the right track. What seems to be a prblem though?
    >>
    >> Just make movie.aspx that will do what you want to do with counter and
    >> user Response.WriteFile.
    >>
    >> you might need to set correct content type though.
    >> Use fidler tool (google it) to see what to set ContentType to when
    >> returning .flv file
    >>
    >> George.
    >>
    >>
    >>
    >> "Alois_Mair" <> wrote in message
    >> news:%23%...
    >>> Hello @ll!
    >>> i just have a questition: i am actually working on my own video comunity
    >>> web site. i already have some nice videos online. For this i want to
    >>> give my Comunity an embed link to embed the videos stored on my webhost
    >>> to their own sites like youtube...
    >>>
    >>> actually this embed looks like this:
    >>>
    >>> <object width="425" height="355">
    >>> <param name="movie" value="player.swf?file=movie.flv"></param>
    >>> <param name="wmode" value="transparent"></param>
    >>> <embed src="player.swf?file=movie.flv"
    >>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>> height="355">
    >>> </embed>
    >>> </object>
    >>>
    >>> but i am not happy with this embed code because the user knows, where
    >>> the player is located also where the file is being stored. With this
    >>> link i also have no possiblity to count the video (the counter is stored
    >>> in mssql)
    >>>
    >>> How can i use an embed link like youtube which looks like this:
    >>> <object width="425" height="355">
    >>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>> <param name="wmode" value="transparent"></param>
    >>> <embed src="movie.aspx?file=movie.flv"
    >>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>> height="355">
    >>> </embed>
    >>> </object>
    >>>
    >>> i want to create an aspx file, which i can use in the embed above. How
    >>> can i do this without using any Flash Streaming Addins?
    >>> cheers Alois
    >>>

    >>
    >>

    >
    >
    George Ter-Saakov, Feb 19, 2008
    #4
  5. Alois_Mair

    Alois_Mair Guest

    Hi, i have no filehandle, so the Response.WriteFile is raising an error. But
    i have found a script, which writes out the embed successfully in fullscreen
    to the browser:

    '***** >8 movie.aspx
    FlashString = "<html><head>"
    FlashString += "<script language=""javascript"" type=""text/javascript"">"
    FlashString += "function ObjectLoad()"
    FlashString += "{"
    FlashString += " if ( objectDestination )"
    FlashString += " {"
    FlashString += " var bodyElement =
    objectDestination.parentElement;"
    FlashString += " if ( bodyElement.objectSource )"
    FlashString += " {"
    FlashString += " bodyElement.innerHTML = ""<embed width=100%
    height=100% fullscreen=yes>"";"
    FlashString += " bodyElement.firstChild.src =
    bodyElement.objectSource;"
    FlashString += " }"
    FlashString += " }"
    FlashString += "}"
    FlashString += "<" & "/" & "script></head>"
    FlashString += "<body objectSource=""player.swf?file=movie.flv""
    FlashString += " onload=""ObjectLoad();"" leftmargin=0 topmargin=0
    scroll=no> <form id=""objectDestination""></form></body></html>"

    Response.Clear()
    Response.AddHeader("Content-Disposition", "inline;")
    'Response.AddHeader("Content-Type", "application/x-shockwave-flash") <=
    This is out commented, because this doesn't work ?!
    Response.Write(FlashString)
    Response.End()

    This Code Snippets in the movie.aspx returns the working flashplayer with
    the given movie. This Works fine. But using this movie.aspx within an embed
    this doesn't work anymore:

    '******* >8 player.aspx
    <object width="425" height="355">
    <param name="movie" value="movie.aspx?file=movie.flv"></param>
    <param name="wmode" value="transparent"></param>
    <embed src="movie.aspx?file=movie.flv" type="application/x-shockwave-flash"
    wmode="transparent" width="425" height="355">
    </embed>
    </object>

    Is this the right way? or should i try to use the Response.WriteFile()? How
    can i use WriteFile?
    Thanks Alois


    "George Ter-Saakov" <> schrieb im Newsbeitrag
    news:%...
    >I do not see the actual line that outputs file to browser.
    >Response.WriteFile
    > Can it be a reason so it does not work?
    >
    > George.
    >
    >
    > "Alois_Mair" <> wrote in message
    > news:...
    >> Hi George,
    >> thank you for your reply, i already have the aspx file with the following
    >> code:
    >>
    >> Response.Clear()
    >> ' set the content type to SWF
    >> Response.ContentType = "application/x-shockwave-flash"
    >> ' add content type header
    >> Response.AddHeader("Content-Type",
    >> "application/x-shockwave-flash")
    >> ' set the content disposition
    >> Response.AddHeader("Content-Disposition",
    >> "inline;filename=player.swf?file=movie.flv")
    >> ' write the buffer with swf file to the output
    >> Response.End()
    >>
    >> this doesn't work?
    >> thank you, Alois
    >>
    >> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >> news:%...
    >>> You are on the right track. What seems to be a prblem though?
    >>>
    >>> Just make movie.aspx that will do what you want to do with counter and
    >>> user Response.WriteFile.
    >>>
    >>> you might need to set correct content type though.
    >>> Use fidler tool (google it) to see what to set ContentType to when
    >>> returning .flv file
    >>>
    >>> George.
    >>>
    >>>
    >>>
    >>> "Alois_Mair" <> wrote in message
    >>> news:%23%...
    >>>> Hello @ll!
    >>>> i just have a questition: i am actually working on my own video
    >>>> comunity web site. i already have some nice videos online. For this i
    >>>> want to give my Comunity an embed link to embed the videos stored on my
    >>>> webhost to their own sites like youtube...
    >>>>
    >>>> actually this embed looks like this:
    >>>>
    >>>> <object width="425" height="355">
    >>>> <param name="movie" value="player.swf?file=movie.flv"></param>
    >>>> <param name="wmode" value="transparent"></param>
    >>>> <embed src="player.swf?file=movie.flv"
    >>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>> height="355">
    >>>> </embed>
    >>>> </object>
    >>>>
    >>>> but i am not happy with this embed code because the user knows, where
    >>>> the player is located also where the file is being stored. With this
    >>>> link i also have no possiblity to count the video (the counter is
    >>>> stored in mssql)
    >>>>
    >>>> How can i use an embed link like youtube which looks like this:
    >>>> <object width="425" height="355">
    >>>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>>> <param name="wmode" value="transparent"></param>
    >>>> <embed src="movie.aspx?file=movie.flv"
    >>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>> height="355">
    >>>> </embed>
    >>>> </object>
    >>>>
    >>>> i want to create an aspx file, which i can use in the embed above. How
    >>>> can i do this without using any Flash Streaming Addins?
    >>>> cheers Alois
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Alois_Mair, Feb 19, 2008
    #5
  6. You are confusing me now.....
    You need to have 2 aspx pages.
    1. First page will produce html with the object tag. (Does not matter how
    you do it with Javascript or not)
    <object width="425" height="355">
    <param name="movie" value="movie.aspx?file=movie.flv"></param>
    <param name="wmode" value="transparent"></param>
    <embed src="movie.aspx?file=movie.flv"
    type="application/x-shockwave-flash" wmode="transparent" width="425"
    height="355">
    </embed>
    </object>

    2. Second page is movie.aspx that should have folowing code.
    ....increment counter.....
    ....output movie....
    Response.Clear();
    Response.ContentType = "application/x-shockwave-flash";
    Response.AddHeader("Content-Type", "application/x-shockwave-flash");
    Response.WriteFile(Server.MapPath("~/mymoviefolder/" + Request[file]));
    Response.End();



    George.

    "Alois_Mair" <> wrote in message
    news:%...
    > Hi, i have no filehandle, so the Response.WriteFile is raising an error.
    > But i have found a script, which writes out the embed successfully in
    > fullscreen to the browser:
    >
    > '***** >8 movie.aspx
    > FlashString = "<html><head>"
    > FlashString += "<script language=""javascript""
    > type=""text/javascript"">"
    > FlashString += "function ObjectLoad()"
    > FlashString += "{"
    > FlashString += " if ( objectDestination )"
    > FlashString += " {"
    > FlashString += " var bodyElement =
    > objectDestination.parentElement;"
    > FlashString += " if ( bodyElement.objectSource )"
    > FlashString += " {"
    > FlashString += " bodyElement.innerHTML = ""<embed width=100%
    > height=100% fullscreen=yes>"";"
    > FlashString += " bodyElement.firstChild.src =
    > bodyElement.objectSource;"
    > FlashString += " }"
    > FlashString += " }"
    > FlashString += "}"
    > FlashString += "<" & "/" & "script></head>"
    > FlashString += "<body objectSource=""player.swf?file=movie.flv""
    > FlashString += " onload=""ObjectLoad();"" leftmargin=0 topmargin=0
    > scroll=no> <form id=""objectDestination""></form></body></html>"
    >
    > Response.Clear()
    > Response.AddHeader("Content-Disposition", "inline;")
    > 'Response.AddHeader("Content-Type", "application/x-shockwave-flash") <=
    > This is out commented, because this doesn't work ?!
    > Response.Write(FlashString)
    > Response.End()
    >
    > This Code Snippets in the movie.aspx returns the working flashplayer with
    > the given movie. This Works fine. But using this movie.aspx within an
    > embed this doesn't work anymore:
    >
    > '******* >8 player.aspx
    > <object width="425" height="355">
    > <param name="movie" value="movie.aspx?file=movie.flv"></param>
    > <param name="wmode" value="transparent"></param>
    > <embed src="movie.aspx?file=movie.flv"
    > type="application/x-shockwave-flash" wmode="transparent" width="425"
    > height="355">
    > </embed>
    > </object>
    >
    > Is this the right way? or should i try to use the Response.WriteFile()?
    > How can i use WriteFile?
    > Thanks Alois
    >
    >
    > "George Ter-Saakov" <> schrieb im Newsbeitrag
    > news:%...
    >>I do not see the actual line that outputs file to browser.
    >>Response.WriteFile
    >> Can it be a reason so it does not work?
    >>
    >> George.
    >>
    >>
    >> "Alois_Mair" <> wrote in message
    >> news:...
    >>> Hi George,
    >>> thank you for your reply, i already have the aspx file with the
    >>> following code:
    >>>
    >>> Response.Clear()
    >>> ' set the content type to SWF
    >>> Response.ContentType = "application/x-shockwave-flash"
    >>> ' add content type header
    >>> Response.AddHeader("Content-Type",
    >>> "application/x-shockwave-flash")
    >>> ' set the content disposition
    >>> Response.AddHeader("Content-Disposition",
    >>> "inline;filename=player.swf?file=movie.flv")
    >>> ' write the buffer with swf file to the output
    >>> Response.End()
    >>>
    >>> this doesn't work?
    >>> thank you, Alois
    >>>
    >>> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >>> news:%...
    >>>> You are on the right track. What seems to be a prblem though?
    >>>>
    >>>> Just make movie.aspx that will do what you want to do with counter and
    >>>> user Response.WriteFile.
    >>>>
    >>>> you might need to set correct content type though.
    >>>> Use fidler tool (google it) to see what to set ContentType to when
    >>>> returning .flv file
    >>>>
    >>>> George.
    >>>>
    >>>>
    >>>>
    >>>> "Alois_Mair" <> wrote in message
    >>>> news:%23%...
    >>>>> Hello @ll!
    >>>>> i just have a questition: i am actually working on my own video
    >>>>> comunity web site. i already have some nice videos online. For this i
    >>>>> want to give my Comunity an embed link to embed the videos stored on
    >>>>> my webhost to their own sites like youtube...
    >>>>>
    >>>>> actually this embed looks like this:
    >>>>>
    >>>>> <object width="425" height="355">
    >>>>> <param name="movie" value="player.swf?file=movie.flv"></param>
    >>>>> <param name="wmode" value="transparent"></param>
    >>>>> <embed src="player.swf?file=movie.flv"
    >>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>> height="355">
    >>>>> </embed>
    >>>>> </object>
    >>>>>
    >>>>> but i am not happy with this embed code because the user knows, where
    >>>>> the player is located also where the file is being stored. With this
    >>>>> link i also have no possiblity to count the video (the counter is
    >>>>> stored in mssql)
    >>>>>
    >>>>> How can i use an embed link like youtube which looks like this:
    >>>>> <object width="425" height="355">
    >>>>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>>>> <param name="wmode" value="transparent"></param>
    >>>>> <embed src="movie.aspx?file=movie.flv"
    >>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>> height="355">
    >>>>> </embed>
    >>>>> </object>
    >>>>>
    >>>>> i want to create an aspx file, which i can use in the embed above. How
    >>>>> can i do this without using any Flash Streaming Addins?
    >>>>> cheers Alois
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    George Ter-Saakov, Feb 19, 2008
    #6
  7. Alois_Mair

    Alois_Mair Guest

    Hello George,

    thank you for your reply. Yes, thats true, i have 2 aspx files. one with the
    embed and the second, which produces the embed object.

    i also have a player (swf) and a flash file (flv) OR a player (swf) and a
    streamed file (rmtp). for this it was my idea to "prepare" the object with
    the player and the movie and give this constellation to the embed object.
    how can i do this with the WriteFile and MapPath?

    Thanks a lot
    Alois


    "George Ter-Saakov" <> schrieb im Newsbeitrag
    news:...
    > You are confusing me now.....
    > You need to have 2 aspx pages.
    > 1. First page will produce html with the object tag. (Does not matter how
    > you do it with Javascript or not)
    > <object width="425" height="355">
    > <param name="movie" value="movie.aspx?file=movie.flv"></param>
    > <param name="wmode" value="transparent"></param>
    > <embed src="movie.aspx?file=movie.flv"
    > type="application/x-shockwave-flash" wmode="transparent" width="425"
    > height="355">
    > </embed>
    > </object>
    >
    > 2. Second page is movie.aspx that should have folowing code.
    > ...increment counter.....
    > ...output movie....
    > Response.Clear();
    > Response.ContentType = "application/x-shockwave-flash";
    > Response.AddHeader("Content-Type", "application/x-shockwave-flash");
    > Response.WriteFile(Server.MapPath("~/mymoviefolder/" + Request[file]));
    > Response.End();
    >
    >
    >
    > George.
    >
    > "Alois_Mair" <> wrote in message
    > news:%...
    >> Hi, i have no filehandle, so the Response.WriteFile is raising an error.
    >> But i have found a script, which writes out the embed successfully in
    >> fullscreen to the browser:
    >>
    >> '***** >8 movie.aspx
    >> FlashString = "<html><head>"
    >> FlashString += "<script language=""javascript""
    >> type=""text/javascript"">"
    >> FlashString += "function ObjectLoad()"
    >> FlashString += "{"
    >> FlashString += " if ( objectDestination )"
    >> FlashString += " {"
    >> FlashString += " var bodyElement =
    >> objectDestination.parentElement;"
    >> FlashString += " if ( bodyElement.objectSource )"
    >> FlashString += " {"
    >> FlashString += " bodyElement.innerHTML = ""<embed width=100%
    >> height=100% fullscreen=yes>"";"
    >> FlashString += " bodyElement.firstChild.src =
    >> bodyElement.objectSource;"
    >> FlashString += " }"
    >> FlashString += " }"
    >> FlashString += "}"
    >> FlashString += "<" & "/" & "script></head>"
    >> FlashString += "<body objectSource=""player.swf?file=movie.flv""
    >> FlashString += " onload=""ObjectLoad();"" leftmargin=0 topmargin=0
    >> scroll=no> <form id=""objectDestination""></form></body></html>"
    >>
    >> Response.Clear()
    >> Response.AddHeader("Content-Disposition", "inline;")
    >> 'Response.AddHeader("Content-Type", "application/x-shockwave-flash") <=
    >> This is out commented, because this doesn't work ?!
    >> Response.Write(FlashString)
    >> Response.End()
    >>
    >> This Code Snippets in the movie.aspx returns the working flashplayer with
    >> the given movie. This Works fine. But using this movie.aspx within an
    >> embed this doesn't work anymore:
    >>
    >> '******* >8 player.aspx
    >> <object width="425" height="355">
    >> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >> <param name="wmode" value="transparent"></param>
    >> <embed src="movie.aspx?file=movie.flv"
    >> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >> height="355">
    >> </embed>
    >> </object>
    >>
    >> Is this the right way? or should i try to use the Response.WriteFile()?
    >> How can i use WriteFile?
    >> Thanks Alois
    >>
    >>
    >> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >> news:%...
    >>>I do not see the actual line that outputs file to browser.
    >>>Response.WriteFile
    >>> Can it be a reason so it does not work?
    >>>
    >>> George.
    >>>
    >>>
    >>> "Alois_Mair" <> wrote in message
    >>> news:...
    >>>> Hi George,
    >>>> thank you for your reply, i already have the aspx file with the
    >>>> following code:
    >>>>
    >>>> Response.Clear()
    >>>> ' set the content type to SWF
    >>>> Response.ContentType = "application/x-shockwave-flash"
    >>>> ' add content type header
    >>>> Response.AddHeader("Content-Type",
    >>>> "application/x-shockwave-flash")
    >>>> ' set the content disposition
    >>>> Response.AddHeader("Content-Disposition",
    >>>> "inline;filename=player.swf?file=movie.flv")
    >>>> ' write the buffer with swf file to the output
    >>>> Response.End()
    >>>>
    >>>> this doesn't work?
    >>>> thank you, Alois
    >>>>
    >>>> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >>>> news:%...
    >>>>> You are on the right track. What seems to be a prblem though?
    >>>>>
    >>>>> Just make movie.aspx that will do what you want to do with counter and
    >>>>> user Response.WriteFile.
    >>>>>
    >>>>> you might need to set correct content type though.
    >>>>> Use fidler tool (google it) to see what to set ContentType to when
    >>>>> returning .flv file
    >>>>>
    >>>>> George.
    >>>>>
    >>>>>
    >>>>>
    >>>>> "Alois_Mair" <> wrote in message
    >>>>> news:%23%...
    >>>>>> Hello @ll!
    >>>>>> i just have a questition: i am actually working on my own video
    >>>>>> comunity web site. i already have some nice videos online. For this i
    >>>>>> want to give my Comunity an embed link to embed the videos stored on
    >>>>>> my webhost to their own sites like youtube...
    >>>>>>
    >>>>>> actually this embed looks like this:
    >>>>>>
    >>>>>> <object width="425" height="355">
    >>>>>> <param name="movie" value="player.swf?file=movie.flv"></param>
    >>>>>> <param name="wmode" value="transparent"></param>
    >>>>>> <embed src="player.swf?file=movie.flv"
    >>>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>>> height="355">
    >>>>>> </embed>
    >>>>>> </object>
    >>>>>>
    >>>>>> but i am not happy with this embed code because the user knows, where
    >>>>>> the player is located also where the file is being stored. With this
    >>>>>> link i also have no possiblity to count the video (the counter is
    >>>>>> stored in mssql)
    >>>>>>
    >>>>>> How can i use an embed link like youtube which looks like this:
    >>>>>> <object width="425" height="355">
    >>>>>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>>>>> <param name="wmode" value="transparent"></param>
    >>>>>> <embed src="movie.aspx?file=movie.flv"
    >>>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>>> height="355">
    >>>>>> </embed>
    >>>>>> </object>
    >>>>>>
    >>>>>> i want to create an aspx file, which i can use in the embed above.
    >>>>>> How can i do this without using any Flash Streaming Addins?
    >>>>>> cheers Alois
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Alois_Mair, Feb 19, 2008
    #7
  8. Your value has such preparation value="movie.aspx?file=movie.flv"

    It tells the flash player to load movie from movie.aspx.

    The movie.aspx in return must return the physical file...Thus you need to
    use WriteFile. And you need to use MapPath just because WriteFile takes
    physical path (like C:\intepub\myfile.flv).

    George.



    "Alois_Mair" <> wrote in message
    news:...
    > Hello George,
    >
    > thank you for your reply. Yes, thats true, i have 2 aspx files. one with
    > the embed and the second, which produces the embed object.
    >
    > i also have a player (swf) and a flash file (flv) OR a player (swf) and a
    > streamed file (rmtp). for this it was my idea to "prepare" the object with
    > the player and the movie and give this constellation to the embed object.
    > how can i do this with the WriteFile and MapPath?
    >
    > Thanks a lot
    > Alois
    >
    >
    > "George Ter-Saakov" <> schrieb im Newsbeitrag
    > news:...
    >> You are confusing me now.....
    >> You need to have 2 aspx pages.
    >> 1. First page will produce html with the object tag. (Does not matter how
    >> you do it with Javascript or not)
    >> <object width="425" height="355">
    >> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >> <param name="wmode" value="transparent"></param>
    >> <embed src="movie.aspx?file=movie.flv"
    >> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >> height="355">
    >> </embed>
    >> </object>
    >>
    >> 2. Second page is movie.aspx that should have folowing code.
    >> ...increment counter.....
    >> ...output movie....
    >> Response.Clear();
    >> Response.ContentType = "application/x-shockwave-flash";
    >> Response.AddHeader("Content-Type", "application/x-shockwave-flash");
    >> Response.WriteFile(Server.MapPath("~/mymoviefolder/" + Request[file]));
    >> Response.End();
    >>
    >>
    >>
    >> George.
    >>
    >> "Alois_Mair" <> wrote in message
    >> news:%...
    >>> Hi, i have no filehandle, so the Response.WriteFile is raising an error.
    >>> But i have found a script, which writes out the embed successfully in
    >>> fullscreen to the browser:
    >>>
    >>> '***** >8 movie.aspx
    >>> FlashString = "<html><head>"
    >>> FlashString += "<script language=""javascript""
    >>> type=""text/javascript"">"
    >>> FlashString += "function ObjectLoad()"
    >>> FlashString += "{"
    >>> FlashString += " if ( objectDestination )"
    >>> FlashString += " {"
    >>> FlashString += " var bodyElement =
    >>> objectDestination.parentElement;"
    >>> FlashString += " if ( bodyElement.objectSource )"
    >>> FlashString += " {"
    >>> FlashString += " bodyElement.innerHTML = ""<embed width=100%
    >>> height=100% fullscreen=yes>"";"
    >>> FlashString += " bodyElement.firstChild.src =
    >>> bodyElement.objectSource;"
    >>> FlashString += " }"
    >>> FlashString += " }"
    >>> FlashString += "}"
    >>> FlashString += "<" & "/" & "script></head>"
    >>> FlashString += "<body objectSource=""player.swf?file=movie.flv""
    >>> FlashString += " onload=""ObjectLoad();"" leftmargin=0 topmargin=0
    >>> scroll=no> <form id=""objectDestination""></form></body></html>"
    >>>
    >>> Response.Clear()
    >>> Response.AddHeader("Content-Disposition", "inline;")
    >>> 'Response.AddHeader("Content-Type", "application/x-shockwave-flash") <=
    >>> This is out commented, because this doesn't work ?!
    >>> Response.Write(FlashString)
    >>> Response.End()
    >>>
    >>> This Code Snippets in the movie.aspx returns the working flashplayer
    >>> with the given movie. This Works fine. But using this movie.aspx within
    >>> an embed this doesn't work anymore:
    >>>
    >>> '******* >8 player.aspx
    >>> <object width="425" height="355">
    >>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>> <param name="wmode" value="transparent"></param>
    >>> <embed src="movie.aspx?file=movie.flv"
    >>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>> height="355">
    >>> </embed>
    >>> </object>
    >>>
    >>> Is this the right way? or should i try to use the Response.WriteFile()?
    >>> How can i use WriteFile?
    >>> Thanks Alois
    >>>
    >>>
    >>> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >>> news:%...
    >>>>I do not see the actual line that outputs file to browser.
    >>>>Response.WriteFile
    >>>> Can it be a reason so it does not work?
    >>>>
    >>>> George.
    >>>>
    >>>>
    >>>> "Alois_Mair" <> wrote in message
    >>>> news:...
    >>>>> Hi George,
    >>>>> thank you for your reply, i already have the aspx file with the
    >>>>> following code:
    >>>>>
    >>>>> Response.Clear()
    >>>>> ' set the content type to SWF
    >>>>> Response.ContentType = "application/x-shockwave-flash"
    >>>>> ' add content type header
    >>>>> Response.AddHeader("Content-Type",
    >>>>> "application/x-shockwave-flash")
    >>>>> ' set the content disposition
    >>>>> Response.AddHeader("Content-Disposition",
    >>>>> "inline;filename=player.swf?file=movie.flv")
    >>>>> ' write the buffer with swf file to the output
    >>>>> Response.End()
    >>>>>
    >>>>> this doesn't work?
    >>>>> thank you, Alois
    >>>>>
    >>>>> "George Ter-Saakov" <> schrieb im Newsbeitrag
    >>>>> news:%...
    >>>>>> You are on the right track. What seems to be a prblem though?
    >>>>>>
    >>>>>> Just make movie.aspx that will do what you want to do with counter
    >>>>>> and user Response.WriteFile.
    >>>>>>
    >>>>>> you might need to set correct content type though.
    >>>>>> Use fidler tool (google it) to see what to set ContentType to when
    >>>>>> returning .flv file
    >>>>>>
    >>>>>> George.
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>> "Alois_Mair" <> wrote in message
    >>>>>> news:%23%...
    >>>>>>> Hello @ll!
    >>>>>>> i just have a questition: i am actually working on my own video
    >>>>>>> comunity web site. i already have some nice videos online. For this
    >>>>>>> i want to give my Comunity an embed link to embed the videos stored
    >>>>>>> on my webhost to their own sites like youtube...
    >>>>>>>
    >>>>>>> actually this embed looks like this:
    >>>>>>>
    >>>>>>> <object width="425" height="355">
    >>>>>>> <param name="movie" value="player.swf?file=movie.flv"></param>
    >>>>>>> <param name="wmode" value="transparent"></param>
    >>>>>>> <embed src="player.swf?file=movie.flv"
    >>>>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>>>> height="355">
    >>>>>>> </embed>
    >>>>>>> </object>
    >>>>>>>
    >>>>>>> but i am not happy with this embed code because the user knows,
    >>>>>>> where the player is located also where the file is being stored.
    >>>>>>> With this link i also have no possiblity to count the video (the
    >>>>>>> counter is stored in mssql)
    >>>>>>>
    >>>>>>> How can i use an embed link like youtube which looks like this:
    >>>>>>> <object width="425" height="355">
    >>>>>>> <param name="movie" value="movie.aspx?file=movie.flv"></param>
    >>>>>>> <param name="wmode" value="transparent"></param>
    >>>>>>> <embed src="movie.aspx?file=movie.flv"
    >>>>>>> type="application/x-shockwave-flash" wmode="transparent" width="425"
    >>>>>>> height="355">
    >>>>>>> </embed>
    >>>>>>> </object>
    >>>>>>>
    >>>>>>> i want to create an aspx file, which i can use in the embed above.
    >>>>>>> How can i do this without using any Flash Streaming Addins?
    >>>>>>> cheers Alois
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    George Ter-Saakov, Feb 19, 2008
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?UmljaGFyZCBSb2NoZQ==?=

    embed element/object

    =?Utf-8?B?UmljaGFyZCBSb2NoZQ==?=, Dec 18, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    343
    Ken Cox [Microsoft MVP]
    Dec 18, 2004
  2. Replies:
    0
    Views:
    345
  3. Andrew Thompson

    <APPLET> or <OBJECT>/<EMBED>?

    Andrew Thompson, Sep 30, 2005, in forum: Java
    Replies:
    0
    Views:
    740
    Andrew Thompson
    Sep 30, 2005
  4. code_wrong

    object to object -- embed instead

    code_wrong, May 21, 2006, in forum: HTML
    Replies:
    4
    Views:
    442
    code_wrong
    May 23, 2006
  5. Jarmo Pertman
    Replies:
    5
    Views:
    128
    Jarmo Pertman
    Aug 2, 2010
Loading...

Share This Page