Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8981065
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T20:14:27+00:00 2026-06-15T20:14:27+00:00

I want to show the hidden input field which is generated with the CActiveForm->fileField()

  • 0

I want to show the hidden input field which is generated with the CActiveForm->fileField()

<?php $form=$this->beginWidget('CActiveForm', array(
                'id'=>'user-_profile-form',
                'enableAjaxValidation'=>false,
                'htmlOptions'=>array(
                    'enctype'=>'multipart/form-data'
                )
            )); ?>
// some code here

<?php echo $form->labelEx($model,'file_upload'); ?>

<?php echo $form->fileField($model,'file_upload'); ?>

// some code here

<?php $this->endWidget(); ?>

the output looks like this

<label for="User_file_upload">File Upload</label>

<input id="ytUser_file_upload" type="hidden" value="" name="User[file_upload]">
<input name="User[file_upload]" id="User_file_upload" type="file">

and i want that the hidden field shows as a normal input field.. because the design is asking for that

would be nice if anybody has a suggestion for me

thanks in advance

EDIT:

here an image of what i need enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T20:14:28+00:00Added an answer on June 15, 2026 at 8:14 pm

    You could do this client side with javascript?

    Looking at this SO post: jQuery: Change element type from hidden to input you could modify it for your form (jsfiddle):

    marker = $('<span />').insertBefore('#ytUser_file_upload');
    $('#ytUser_file_upload').detach().attr('type', 'text').insertAfter(marker).focus();
    marker.remove();​
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a hidden field, which has the following markup: <input type=hidden name=ctl00$ContentPlaceHolder1$LinksOverview1$ProductView$ctrl1$ctl01$ctl00$DescriptionOfLink$QuestionDivInfo id=ContentPlaceHolder1_LinksOverview1_ProductView_ctrl1_ctl00_3_DescriptionOfLink_3_QuestionDivInfo_3
I want to show array objects at the same time in different 10 labels.
I have following HTML code. writer input field is text filed. but I want
I´ve got this code inside a php file. It should show and hide a
I want to show hidden span when button is click. My html looks like:
I want to validate a form to make sure a user writes in a
I want to show a modal popup when a user click on an asp
I want show an information page after success db opartions. And after the info
I want show annotation view (above one of my pin) after load map. For
hii I want show a pop up Dialog box when i click on to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.